sql - OLE DB provider [OraOLEDB.Oracle] for linked server [ORA] returned message ORA-00936: missing expression -
i having issues openquery.
i have simple linked server sql:
select [item_serial].[serial_no] , [item_serial].[sub_seq_no_firm] , [item_serial].[item_no] [ora]..[ssdigico].[item_serial] order [item_serial].[serial_no]
this runs smooth, no problem...
now trying use openquery approach improve performance such as:
select * openquery(ora,' select [item_serial].[serial_no] , [item_serial].[sub_seq_no_firm] , [item_serial].[item_no] [ssdigico].[item_serial] order [item_serial].[serial_no] ')
and reason following error message:
ole db provider "oraoledb.oracle" linked server "ora" returned message "ora-00936: missing expression". msg 7321, level 16, state 2, line 1 error occurred while preparing query "
does 1 got clue why error?
thanks.
oracle not use square brackets around tables or columns. code should be:
select * openquery(ora,' select item_serial.serial_no , item_serial.sub_seq_no_firm , item_serial.item_no ssdigico.item_serial order item_serial.serial_no ')
Comments
Post a Comment