Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: OPENROWSET using ORACLE and DATEDIFF
On Mon, 14 Oct 2002 16:22:07 +0100, "Andy" <nospam_at_nospam.com> wrote:
> FROM IGS.EVT_AGENT_ACTIVITY
> WHERE DATEDIFF(''H'',TO_DATE(AA_TIME_STAMP,''yyyy/mm/dd:hh:mi:ss'') ,
>TO_DATE(''2002/10/13:11:00:00'',''yyyy/mm/dd:hh:mi:ss''))<2
> ')
You are mixing Oracle-based function and Microsux functions.
You need to either
- rewrite the sql to use Oracle functions only (and run it as a
passthrough query)
-or rewrite the sql to use Microsux functions only.
In Oracle the datediff function is not applicable, you just subtract two dates, in Microsux the to_date function doesn't exist.
I would try to prevent using this group as a debugging tool.
Regards
Sybrand Bakker, Senior Oracle DBA
To reply remove -verwijderdit from my e-mail address Received on Mon Oct 14 2002 - 11:52:26 CDT