mysql 没有rownum 又想查出来内部id

SELECT @rownum:=@rownum+1,t.* rownum From
(SELECT @rownum:=0,cq_fzz_imagedata.* FROM cq_fzz_imagedata   ORDER BY house_no ) t

你可能感兴趣的:(mysql)