Re: HELP on PL/SQL problem

From: Scott Urman <surman_at_oracle.com>
Date: 3 Mar 1995 19:29:04 GMT
Message-ID: <3j7qm0$9ml_at_dcsun4.us.oracle.com>


In article <3j3um6$mul_at_polo.iquest.com>, brink_at_iquest.com writes:
|> Is it possible to execute a dynamic SQL statement from PL/SQL?
|>
|> I want to build an SQL statement on the fly and execute it as in the following
|> example.
|>
|> CREATE OR REPLACE PROCEDURE SYNC_ALL (arg IN NUMBER) is
|> sqlStmt CHAR(255);
|> BEGIN
|> sqlStmt := 'insert into tableName values (1,2,3)';
|> EXECUTE IMMEDIATE :sqlStmt;
|> END SYNC_ALL;
|>
|> Our local site ORACLE support says PL/SQL does not support dynamic
|> SQL? Is this true? Any suggestions appreciated.
|>

Correct. PL/SQL doesn't have dynamic capability. At least 2.0 (shipped with Oracle7) doesn't. But PL/SQL 2.1 (with Oracle 7.1) does - the DBMS_SQL package. Received on Fri Mar 03 1995 - 20:29:04 CET

Original text of this message