Skip to Main Content

SQL Developer

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ORA-00904: "DATEADD": invalid identifier

890478Oct 12 2011 — edited Oct 12 2011
Hi everyone, i am not sure whether this is the right place to post this but i have a problem to ask.

select * from openquery(serverlinkeodwmain, 'SELECT COUNT(CNTR_N) cnt FROM OPS_DLY_AGING_DTL
WHERE BATCH_ID = DateADD(day , datediff(day, 0, getdate()), 0)')

i am trying to get this code to work but i seem to keep getting the error:
OLE DB provider "MSDAORA" for linked server "serverlinkeodwmain" returned message "ORA-00904: "DATEADD": invalid identifier
".

is it because dateadd is sql and not oracle?

please help. i am a noob at this.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 9 2011
Added on Oct 12 2011
1 comment
2,965 views