34,837
社区成员




declare test_cursor4 cursor scroll for
select StudyID
from [PACS].[dbo].MEDICAL_LOGON
open test_cursor4
DECLARE @examid int
WHILE @@fetch_status = 0
begin
fetch next from test_cursor4 into @examid
print @examid
end
close test_cursor4--关闭游标
deallocate test_cursor4--释放游标