Home » SQL & PL/SQL » SQL & PL/SQL » RECORD Parameter
RECORD Parameter [message #3380] Tue, 24 September 2002 08:53 Go to next message
Marjorin Mendoza
Messages: 15
Registered: September 2002
Junior Member
I have a cursor named PaymentCursor and it fetches its record to PaymentRecord (FETCH PaymentCursor INTO PaymentRecord). Can I pass my PaymentRecord in another procedure as a parameter? How can it be declared in the receiving Procedure?
Re: RECORD Parameter [message #3383 is a reply to message #3380] Tue, 24 September 2002 10:03 Go to previous messageGo to next message
Todd Barry
Messages: 4819
Registered: August 2001
Senior Member
Sure, just declare the parameter with the same datatype as PaymentRecord. If the definition does not already exist in a package spec, you will need to put it in one to use it in a procedure declaration.
Re: RECORD Parameter (follow-up question) [message #3390 is a reply to message #3383] Tue, 24 September 2002 17:24 Go to previous messageGo to next message
Marjorin Mendoza
Messages: 15
Registered: September 2002
Junior Member
Declaration -->
RecordPayable PAYABLE%ROWTYPE;

Calling Procedure -->
Payment.ClosePayableRecords(RecordPayment);

Receiving Procedure -->
PROCEDURE ClosePayableRecords(
PayableRecord PAYABLE%ROWTYPE)

Error Encountered -->
PLS-00306: wrong number or types of arguments in call to 'CLOSEPAYABLERECORDS'

--Is there something wrong with my code or do I missed something during my call?
Re: RECORD Parameter (follow-up question) [message #3392 is a reply to message #3383] Tue, 24 September 2002 22:57 Go to previous message
Marjorin Mendoza
Messages: 15
Registered: September 2002
Junior Member
Trying a simple test really did the work ... My problem lies on the RECORD inheriting records of a cursor since I still might have to create a USER DEFINED TYPE RECORD in order to declare it in the package header. Thanks for your help :)
Previous Topic: Re: Getting TOAD working
Next Topic: Re: create table in dbms_sql not possible (drop is possible)???
Goto Forum:
  


Current Time: Tue May 07 23:12:25 CDT 2024