Hi all, Can someone please help???
I am trying to delete all data from table in DB2 using openquery in SP: **EXEC(' DELETE FROM OPENQUERY(DMFRC1,'' SELECT FROM USRMNT.UNIQ_AH_ACCT '') ')*
Receiving the following error: Cannot execute the query " SELECT FROM USRMNT.UNIQ_AH_ACCT*
asked Dec 27, 2010 at 09:36 AM in Default
You probably want to do this using a pass-through query against DB2 instead.
Have a look at EXECUTE AT (http://msdn.microsoft.com/en-us/library/ms188332.aspx ) which is a way to use EXECUTE with a DELETE-statement, passing the name of a linked server as a parameter.