Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: passing ref cursor on a procedure
<span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>Example
<span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>
<span lang=EN-US
style='font-size:10.0pt;font-family:Arial;color:navy'>Package ll is
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>Type lrec is record(
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>????? A ?integer,
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>????? B? varchar2(72));
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>Type lrectype is REF CURSOR return lrec;
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>Procedure getl( par1 in varchar2,
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>?????????????????????? Xcursor IN OUT lrectype);
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>End;
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>Now ,
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>
<font size=2 color=navy
face=Arial><span lang=EN-US style='font-size:10.0pt;font-family:Arial;
color:navy'>HOW do I execute procedure getl from sqlplus?
<span lang=EN-GB
style='font-size:10.0pt;font-family:Arial;color:navy'>
<span lang=EN-US
style='font-size:10.0pt;color:navy'>Kind Regards,<font
color=navy>
<span
lang=EN-GB style='font-size:12.0pt;color:navy'>
<span lang=EN-US
style='font-size:10.0pt;color:navy;font-weight:bold'>Hatzistavrou Yannis<font
color=navy>
?
<span
lang=EN-US style='font-size:10.0pt;font-family:Tahoma'>-----Original
Message-----
From: Regis Biassala
[mailto:[EMAIL PROTECTED]
Sent: Wednesday,
June 04, 2003<span lang=EN-US
style='font-size:10.0pt;font-family:Tahoma'> <font
size=2 face=Tahoma>6:05
PM<span lang=EN-US style='font-size:
10.0pt;font-family:Tahoma'>
To: Multiple recipients of list
ORACLE-L
Subject: RE: passing ref cursor on
a procedure
<font size=3
face="Times New Roman">
<font size=2 color=blue
face=Arial>example
<p class=MsoNormal style='margin-right:0cm;margin-bottom:12.0pt;margin-left:
36.0pt'><span style='font-size:10.0pt;font-family:
Tahoma'>-----Original Message-----
From: Hatzistavrou John
[mailto:[EMAIL PROTECTED]
Sent: Wednesday, June 04, 2003
2:40 PM
To: Multiple recipients of list
ORACLE-L
Subject: passing ref cursor on a
procedure
<span lang=EN-US
style='font-size:10.0pt;font-family:Arial'>Dear
All,
<span lang=EN-US
style='font-size:10.0pt;font-family:Arial'>I have a vendor procedure which I
wish to run . <span
lang=EN-US style='font-size:10.0pt;font-family:Arial'>This procedure
takes as input variables a varchar and a ref_cursor.
<span lang=EN-US
style='font-size:10.0pt;font-family:Arial'>I know the query that is related to
the ref_cursor and I wish to implicitly pass it to the procedure .<span
lang=EN-US> <span lang=EN-US style='font-size:
10.0pt;font-family:Arial'>How can this be done?
<span
style='font-size:10.0pt'>Kind Regards,
<font size=3
face="Times New Roman">
<span
style='font-size:10.0pt;font-weight:bold'>Hatzistavrou Yannis
This electronic transmission is strictly confidential and intended solely
for the addressee. It may contain information which is covered by legal,
professional or other privilege. If you are not the intended addressee,
you must not disclose, copy or take any action in reliance of this
transmission. If you have received this transmission in error,
please notify the sender as soon as possible.
This footnote also confirms that this message has been swept
for computer viruses.