Re: using execute immediate for create table and then insert

From: Gints Plivna <>
Date: Mon, 2 Mar 2009 14:48:37 +0200
Message-ID: <>

Because Oracle verifies referenced objects in anonymous block and cannot find xxdl_po_vendors_enc table. That's the __nice__ feature of dynamic sql (ddl) as soon as you start using it, you have to use it for all dynamically created objects.
So better think again whether you really need to create this table at runtime and whether there isn't less complex approach creating it normally as temporary or permanent table.

Gints Plivna

2009/3/2 Kumar Madduri <>:
> Hi All
> This does not work when I put the execute immediate and insert in the same
> block (which I hashed). But if I execute the execute immediate portion in
> another anyonymous block, it works fine (both the create and the insert).
> When I try to put them to gether like below, the insert tries to use
> xxdl_po_vendors_enc and says it cannot find the table. Is it because the
> pl/sql block does not know about the table at compile time? Is there
> any workaround for this ?

Received on Mon Mar 02 2009 - 06:48:37 CST

Original text of this message