Home » SQL & PL/SQL » SQL & PL/SQL » mutiple cursor (10g windows)
mutiple cursor [message #308835] Tue, 25 March 2008 11:19 Go to next message
oracle_coorgi
Messages: 185
Registered: September 2006
Location: INDIA-karnataka
Senior Member
hi
how can i use multiple cursor variable
in one begin and end procedure

i have created package with three cursor as %rowtype variable say v_cu1 v_cu2 v_cu3
i need to call these in one begin and end statment i cannot use if condition because its not necssary
create pn package
...........
v_cu1  %rowtype;
v_cu2  %rowtype;
v_cu3  %rowtype;
.......
end package;
create proce body;
............
begin--
open c1
FETCH c1 INTO v_cu1;
open c2
FETCH c2 INTO v_cu2;
open c3
FETCH c3 INTO v_cu3;

insert into ti(xxxxx) (v_cu1);
...........
insert into ti(yyy) (v_cu2);
......
insert into t4(ggg) (v_cu3);
.......
end if;
end loop;
close c1;
end loop;
close c2;
end loop;
close c3;
end;
end procname;
Re: mutiple cursor [message #308837 is a reply to message #308835] Tue, 25 March 2008 11:33 Go to previous messageGo to next message
Michel Cadot
Messages: 64139
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
1/ Your insert statement is still invalid, you should read the doc
2/ There is no loop but you "end loop"
3/ What does "create proce body;" means?
4/ You still don't want to post the actual code.
5/ As usual you neither close your previous topics nor give feedback.

So You're On Your Own (YOYO).

Regards
Michel
Re: mutiple cursor [message #309296 is a reply to message #308837] Thu, 27 March 2008 01:31 Go to previous message
oracle_coorgi
Messages: 185
Registered: September 2006
Location: INDIA-karnataka
Senior Member
hi
Michel and others got it and corrected
the sequence of cursor loop, was wrong .
for some reason i did not paste or send whole script of the package as it had around 2000.. line code and it was offcial...
iwas sending sample code..
Anyway thanxs for all support michel and others for the response for/to posts
i heartly say thanxs to all of you
wish to interact more
anyway has i was very busy with work i could not close some of my post i will do it later
created procedure and package and executed
waiting for the responce hope there is no perfromance issue on it..

thanxs a lot
Previous Topic: use of functions and procedure
Next Topic: Spilit Word in more than one field
Goto Forum:
  


Current Time: Thu Dec 08 10:16:47 CST 2016

Total time taken to generate the page: 0.08831 seconds