如何确定游标指向了哪一行
来源:百度知道 编辑:UC知道 时间:2024/06/04 08:03:17
--以SQL05为例取第50行
declare Roy SCROLL CURSOR FOR
with c
as
(select 1 as ID
union all
select ID+1 from c where ID<50)
select * from C
open roy
fetch ABSOLUTE 50 from roy
close roy
deallocate roy
UC知道是一部内容开放、自由的互动网络百科全书
客观、专业、权威的知识性百科全书
来源:百度知道 编辑:UC知道 时间:2024/06/04 08:03:17
--以SQL05为例取第50行
declare Roy SCROLL CURSOR FOR
with c
as
(select 1 as ID
union all
select ID+1 from c where ID<50)
select * from C
open roy
fetch ABSOLUTE 50 from roy
close roy
deallocate roy