请教个有点复杂的sql语句(内联视图)
数据表stud_db,字段yuwengridview上有A、B、C三列,我想让A显示字段yuwen的前20条记录,B列显示字段yuwen 21—40条记录,依此类推
select a.yumen as a,b.yumen as b,c.yumen as c from
(select yuwen from
(select * from stud_db order by xx)where rownum<=20) a,
(select yuwen from
(select * from stud_db order by xx)where rownum >=21 andrownum<=40) b,
(select yuwen from
(select * from stud_db order by xx)where rownum >=41 andrownum<=60) c
大虾帮忙详细解释下这条sql语句,谢谢!
[ 本帖最后由 fyz520 于 2010-10-31 11:53 编辑 ]