execute immediate 'insert into DVD.TMP_DVD_PRICE select * from ' || l_table;
within a package.
It worked fine in devt (I was connecting as the schema owner) but in UAT it is failing on connect with a different account.
The new account has permissions on the package the command is in. Do I need to grant insert rights to this account also? Or is there any other reason that it might be failing?
I'm getting back a generic error msg - I will contact the DBA team about the exact error. As this may take some time if anyone knows whether executing SQL dynamically changes the way permissions should be applied (i.e. that the privs to the package are not enough for the objects referenced in the dynamic SQL to be recognisable) I would be very grateful.
Bookmarks