Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Probably Simple Question - Execute immediate - confused by sytax
John Doe wrote:
> Oracle, Sybase, Ingres & Informix all have an "EXECUTE IMMEDIATE" command with
> slight variations. I get the idea, we immediately parse and excute some dynamic
> SQL, PL/SQL block etc., Makes sense to me. But, do I have a choice? I can't
> just use "EXECUTE" can I? The only way I can think of to *not* parse and
> immediately execute a piece of dynamic SQL is to use dbms_sql and then I can
> parse and then execute a half hour later if I want. In other words, an
> "EXECUTE IMMEDIATE" command syntactically implies to me that there is an EXECUTE
> command with a few variations - like maybe EXECUTE DEFFERED, EXECUTE
> SOMEOTHERTIME.. etc., but they don't seem to exist. Some it seems to be a two
> word command with no variations - is this correct? For example, I can't alter
> database datafile drop.. I can only offline drop, or offline.. So.. after this
> meandering, I guess my question is are there any variations to this syntax? Is
> it faster then dbms_sql.parse dbms_sql.execute etc.,, ?
>
> Little confused
> Thanks,
> D
There are no variations on the theme. It is EXECUTE IMMEDIATE and that is it. And yes it is very substantially faster than anything involving the DBMS_SQL package though there are some things that can be done in DBMS_SQL that can not be done by EXECUTE IMMEDIATE. Daniel A. Morgan Received on Thu May 17 2001 - 20:52:05 CDT
![]() |
![]() |