Home » SQL & PL/SQL » SQL & PL/SQL » Running SQL script/file
Running SQL script/file [message #36036] Wed, 31 October 2001 05:02 Go to next message
Messages: 2
Registered: October 2001
Junior Member
Is it possible, and if so how, to run a file that contains SQL (a SQL script) from within a stored procedure?


Re: Running SQL script/file [message #36042 is a reply to message #36036] Wed, 31 October 2001 13:57 Go to previous messageGo to next message
andrew again
Messages: 2577
Registered: March 2000
Senior Member
you can use DBMS_PIPE to invoke an OS command. The OS command is then to run an OS script whoich invokes sqlplus which in turn runs your script. In general an SQL script will have sql*plus specific commands like "set pagesize 56" etc resulting in SQL*plus being the only environment capable of running it.


Re: Running SQL script/file [message #36046 is a reply to message #36036] Thu, 01 November 2001 03:42 Go to previous message
Messages: 35
Registered: March 2001

Look at the system_util package on this site.
It has a procedure that enables you to call
OS scripts from inside PL/SQL.


Have fun

Previous Topic: Date problem
Next Topic: Insert Multiple values on an If statement
Goto Forum:

Current Time: Sat May 18 14:58:05 CDT 2024