mysql中查詢規(guī)則,mysql怎么查詢都有哪些序列號(hào)?
有以下兩種方法可查詢:
第一種方法:select (@i:=@i+1) as i,table_name.* from table_name,(select @i:=0) as it
第二種方法:
set @rownum=0;
select @rownum:=@rownum+1 as rownum, t.username from auth_user t limit 1,5;
希望本文所述對(duì)大家MySQL數(shù)據(jù)庫(kù)計(jì)有所