0
votes
  • Linked Server Name:CBSLINKED //Oracle 10g
  • Name of Database if oracle : CBSIVRDB
  • Name of Stored Procedure : FIU_INSERT
  • having parameter as (FromDate,ToDate)
  • My DB: SQL server R2

execute ('call CBSIVRDB.FIU_INSERT ('' TO_DATE(''01-JUN-2014'',DD-MMM-YYYY) '',''TO_DATE(''30-JUN-2014'',DD-MMM-YYYY)'') ') at CBSLINKED

Error:

OLE DB provider "MSDAORA" for linked server "CBSLINKED" returned message "ORA-00907: missing right parenthesis"

1
You are missing the '' in front of DD-MMM. But here might be more problems though. - Jens Krogsboell
you mean like this 'DD-MMM-YYYY' - Ganesh_Devlekar
I have posted an answer for you. - Jens Krogsboell

1 Answers

1
votes

Try this:

CBSIVRDB.FIU_INSERT (TO_DATE(''01-JUN-2014'',''DD-MON-YYYY''),TO_DATE(''30-JUN-2014'',''DD-MON-YYYY''))

or more precisely

execute ('call CBSIVRDB.FIU_INSERT (TO_DATE(''01-JUN-2014'',''DD-MON-YYYY''),TO_DATE(''30-JUN-2014'',''DD-MON-YYYY''))') at CBSLINKED