Home » SQL & PL/SQL » SQL & PL/SQL » UTL_FILE (ora 9.2.0.6)
UTL_FILE [message #290339] Fri, 28 December 2007 07:08 Go to next message
ganeshsv
Messages: 51
Registered: January 2006
Member
Hi,

Is it possible to pass utl_file.file_type to a procedure which will be called through Execute immediate method.

DECLARE
A UTL_FILE.FILE_TYPE;
BEGIN
EXECUTE IMMEDIATE 'PROC_NAME('||A||')';
END;


where Proc_name expects in parameter of type UTL_FILE.FILE_TYPE;

Thanks
GS
Re: UTL_FILE [message #290344 is a reply to message #290339] Fri, 28 December 2007 07:24 Go to previous messageGo to next message
Michel Cadot
Messages: 64102
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
I didn't try it but this is surely not the way you use it.
More "execute immediate 'proc(:1)' using a;"

But why not simply "proc(a);"?

Regards
Michel
Re: UTL_FILE [message #290350 is a reply to message #290344] Fri, 28 December 2007 07:42 Go to previous messageGo to next message
ganeshsv
Messages: 51
Registered: January 2006
Member
Hi Michel,

Thanks. But when I tried to execute with USING method,
PLS-00457: expressions have to be of SQL types.

Is there any way to achieve this?

THanks
GS

Re: UTL_FILE [message #290357 is a reply to message #290350] Fri, 28 December 2007 09:04 Go to previous message
Michel Cadot
Messages: 64102
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
No.
Maybe another way but as you didn't tell us what you finally want to achieve we can't help.

Regards
Michel
Previous Topic: PL/SQL procedures doubt
Next Topic: nested tables (split from hijacked thread)
Goto Forum:
  


Current Time: Fri Dec 02 18:59:40 CST 2016

Total time taken to generate the page: 0.32851 seconds