写的顺序:select ... from... where.... group by... having... order by.. limit [offset,] (rows) 从0开始取几条数据 执行顺序:from... where...group by... having.... select ... order by... limit