标签:mysql 自动序号
select (@rowNO := @rowNo+1) AS rowno,field1,field2,field3 from
(select field1,field2,field3 from table_name where field3 = ‘2012-04-21‘) a,
(select @rowNO :=0) b
mysql在查询结果中自动添加序号字段列
原文地址:http://blog.csdn.net/xiashulin/article/details/45531393