Re: using execute immediate for create table and then insert
Date: Mon, 2 Mar 2009 12:58:39 +0000
Another small thing; this may just be an artefact of the example, but you could simplify and improve by replacing the cursor FOR loop and nested insert with a simple insert:
insert into xxdl.xxdl_po_vendors_enc
(vendor_id, vendor_name, num_1099, num_1099_enc, attribute15) select vendor_id
where attribute15 is null
Thus avoiding the row-by-row fetch. Oh, and if it really needs to be dynamic, it's easier - because there are no bind variables to worry about.
Regards NigelReceived on Mon Mar 02 2009 - 06:58:39 CST