开发者

t-sql table join

开发者 https://www.devze.com 2022-12-10 01:15 出处:网络
Is there any way I can do a join between two tables where the resulting table has only the columns of the left table without the need to discriminate all the columns na开发者_StackOverflow中文版mes in

Is there any way I can do a join between two tables where the resulting table has only the columns of the left table without the need to discriminate all the columns na开发者_StackOverflow中文版mes in the select?


You can do this:

Select LeftTable.*
From LeftTable
    Inner Join RightTable
        On LeftTable.Id = RightTable.Id


Select T.* from tbl1 T, tbl2 J


You mean something like

Select t1.id, t1.name, t1.age FROM t1 INNER JOIN t2 ON t1.id = t2.id 
WHERE t2.Something = Something
0

精彩评论

暂无评论...
验证码 换一张
取 消