Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

how to execute a sql from a pl/sql anonymous block

User_R5AHCOct 30 2015 — edited Nov 3 2015

Hi, fellows!

I had a PL/SQL which output generates a sql script:

DECLARE

fileHandler UTL_FILE.FILE_TYPE;

BEGIN

    fileHandler := UTL_FILE.FOPEN('FULL_BACKUP', 'cedo_alteram.sql', 'W');

...

END

/

I had tried to use (inside of the pl/sql script), the following:

@cedo_alteram.sql

@@cedo_alteram.sql
EXECUTE IMMEDIATE 'EXECUTE IMMEDIATE 'cedo_alteram.sql';'

But no results I had obtained.

Is there any way I can run my cedo_alteram.sql script from my PL/SQL script, please?

I appreciate any tips you provide me.

Thanks, in advance,

Luiz

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 1 2015
Added on Oct 30 2015
7 comments
2,289 views