日期:2014-05-20  浏览次数:20711 次

select 的内联语句?
我有两张表   biao1  
  id     name
  1       北京
biao2
  id     city
1         海淀区
  怎么在DATAGRID显示出来
北京     海淀
怎么写那个SELECT语句  
谢谢

------解决方案--------------------
select a.name ,b.city from biao1 a,biao2 b where a.id=b.id
------解决方案--------------------
应该是这样的:
select biao1.name,biao2.city from baio1 join biao2 on biao1.id=biao2.id
------解决方案--------------------
select biao1.name ,biao2.city from biao1 left join biao2 on biao1.id=biao2.id