Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: PLS-00225: subprogram or cursor reference is out of scope: REF CURSOR required?

Re: PLS-00225: subprogram or cursor reference is out of scope: REF CURSOR required?

From: DA Morgan <damorgan_at_psoug.org>
Date: Wed, 14 Jun 2006 16:16:59 -0700
Message-ID: <1150327021.128181@bubbleator.drizzle.com>


chilecayenne_at_yahoo.com wrote:

> Sybrand Bakker wrote:

>> On 14 Jun 2006 09:30:11 -0700, chilecayenne_at_yahoo.com wrote:
>>
>>> I thought you could use one cursor's fields in another cursor, as long
>>> as it was declared after the primary one....
>> No you can't, as a cursor is nothing more than a pointer to a piece of
>> memory.
>> You need to fetch the cursor in a *record*, which can be bound to the
>> cursor as follows
>>
>> cursor c1 is ... etc
>>
>> r1 c1%rowtype;
>>
>> You can refer to the components of a record in a cursor definition.
>> A cursor definition can also have *parameters*, just as procedures and
>> functions.
>>
>> Why you until now used a REF CURSOR beats me. Probably because you are
>> unfamiliar with the PL/SQL reference manual, in which this is all
>> documented.
>>
> 
> Thank you for the quick reply. I am working on the run...was run out of
> New Orleans by Katrina...and while I have machines...I have NO
> documentation really to go by...just found some old examples here and
> there....and looking on the web and USENET.
> 
> :-)
> 
> I think I figured a way around this with your suggestions. Thank you,
> 
> cc

Online docs can be found at:
http://tahiti.oracle.com

Online functional demos can be found at: http://www.psoug.org ... Click on Morgan's Library

-- 
Daniel A. Morgan
University of Washington
damorgan_at_x.washington.edu
(replace x with u to respond)
Puget Sound Oracle Users Group
www.psoug.org
Received on Wed Jun 14 2006 - 18:16:59 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US