wilin
wilin
posts - 6,comments - 3,trackbacks - 0
oracle 分页查询语句:
select * from ( select row_.*, rownum rownum_ from (sql--你要查询的语句,支持order by) row_ where rownum <=MAXROW ) where rownum_ >MINROW

示例:
insert into M2_USER_POINT (id, iuserid, iconsumepoint, isumepoint, iisdelete)
select seq_m2_user_point.nextval as id ,iuserid, iconsumepoint, isumepoint,iisdelete from ( select row_.*, rownum rownum_ from (
select  iuserid, iconsumepoint, isumepoint,'0' as iisdelete
from v_club_point
) row_ where rownum <= 10000) where rownum_ >0;
posted on 2005-08-15 09:16 wilin 阅读(206) 评论(0)  编辑  收藏 所属分类: 数据库相关

只有注册用户登录后才能发表评论。


网站导航: