首页 > 数据库技术 > 详细

mysql多表查询

时间:2017-02-05 11:08:16      阅读:210      评论:0      收藏:0      [点我收藏+]
select area from areas where cityid=(select cityid from cities where city like 杭州%) and id!=(select min(id) from areas where cityid=(select cityid from cities where city like 杭州%));

select area from areas where cityid=(select cityid from cities where id=(select min(id) from cities where  provinceid=(select provinceid from provinces where province like 上海%)));

 

mysql多表查询

原文:http://www.cnblogs.com/thankyouGod/p/6366937.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!