Welcome toVigges Developer Community-Open, Learning,Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
235 views
in Technique[技术] by (71.8m points)

sql - How do I view records from a table in a different schema?

Besides using linked server, how do I view records from a table in a different schema?

so if I have table in [eg].[info] and another table in [ie].[info], how do I join them together? That is one schema is [eg] and the other is schema [ie].


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

You need to alias the tables with AS (which you should always do anyway):

FROM eg.info AS info1
JOIN ie.info AS info2

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to Vigges Developer Community for programmer and developer-Open, Learning and Share
...