Update table using linked server Openquery
I tried this code and got the following error so far, maybe someone can help?
UPDATE a
SET a.MMDWNO = '21'
FROM OPENQUERY(NMIIFLIB,
'select * from MVXCDTANSN.MITMAS WHERE MMITTY = ''25''') a
Mistake:
OLE DB provider "MSDASQL" for linked server "NMIIFLIB" returned message "[IBM] [ODBC driver for iSeries access] [DB2 UDB] SQL7008 - MITMAS in MVXCDTANSN is not valid to work."
Msg 7343, Level 16, State 4, Line 1
OLE DB Provider "MSDASQL" for linked server "NMIIFLIB" could not update table "[MSDASQL]".
The select statement works fine, but when I try to update I always stuck with it.
+3
user1088172
source
to share