Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: SQL%ROWCOUNT in an implicit cursor.
Hi
Use a temporary variable
temp_num := 0;
for C in (
select * from Y)
loop (
insert into Z
if mod(temp_num,20) = 0 then
commit;
end if;
temp_num := temp_num + 1;
)
Hope this help
Good luck
pradhan
ken wrote:
> hi there,
>
> I need to make a commit every 20 records, the cursor i have which is an
> implicit one, looks like this:
>
> for C in (
> select * from Y)
> loop (
> insert into Z
> )
> IF record_inserted = 20
> commit;
> End If;
>
> How do I code the record_inserted section??? SQL%ROWCOUNT only returns
> the total number of records in the implicit cursor right?
>
> Thanks !!!
> Gojo.
Received on Sun Jun 04 2000 - 00:00:00 CDT