Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Problem with fetch@cursor
Hello Guys,
I have the following cursor declared
cursor allcount (st_pol varchar2, ed_pol varchar2)is select a.polnum,polfrq,servun,taxsta,covsta,covdue,nxtdte,plnnum,
polmod,coveff,nonfor,decode(nonfor,'ETI','POETI',
'RPU','PORPU',
'POAUT') forcode
from covmas b,polmas a /*+ POLMAS_PK_POLNUM */ where b.polnum = a.polnum and b.covnum = 1 and b.covdue > b.coveff and a.polnum between nvl(st_pol,a.polnum) and nvl(ed_pol,a.polnum);
I use it as follows
...
open allcount( 'xxx','yyyy' );
loop
fetch allcount into c; exit when allcount%notfound; ..
The problem is that all the fetches return quickly except the last one that is suppose to return not found. Indexes are on polmas.polnum and covmas.polnum+covmas.covnum
Thanks for any help as to what can be causing this problem.
Delton.
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
Received on Fri Sep 10 1999 - 12:01:31 CDT