Ed Heal Ed Heal - 1 year ago 82
SQL Question

Dynamic SQL - Check syntax and semantics

With Oracle dynamic SQL one is able to execute a string containing a SQL statement. e.g.

l_stmt := 'select count(*) from tab1';
execute immediate l_stmt;

Is it possible to not execute
but check that the syntax and semantics is correct programmitically?

Answer Source

I think that the only "solution" is to use DBMS_SQL.PARSE().

It is not perfect but it is the best that you can get