综合使用union和limit区分结果并限制返回结果集的条数

时间:2014-05-31 01:47:26   收藏:0   阅读:218
bubuko.com,布布扣
select * from channel where pid=0 union select * from channel where pid=1 union select * from channel where pid=3 limit 5,10
bubuko.com,布布扣

这里的limit限制了返回的union(合并)后的结果集,

综合使用union和limit区分结果并限制返回结果集的条数,布布扣,bubuko.com

评论(0)
© 2014 mamicode.com 版权所有 京ICP备13008772号-2  联系我们:gaon5@hotmail.com
迷上了代码!