Bug 436154 - JPQL current_timestamp on Oracle 9+ is using SYSDATE so no millis available
Summary: JPQL current_timestamp on Oracle 9+ is using SYSDATE so no millis available
Status: NEW
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Eclipselink (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P3 major (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard: oracle
Keywords:
Depends on:
Blocks:
 
Reported: 2014-05-29 07:23 EDT by howard kelsey CLA
Modified: 2022-06-09 10:06 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description howard kelsey CLA 2014-05-29 07:23:53 EDT
Any jpql query containing current_timestamp in the select clause or where clause on Oracle uses the SYSDATE function instead of the SYSTIMESTAMP which means there will be no millis.

This is due to to the code in OraclePlatform#initializePlatformOperators which overrides the TODAY operator set in DatabasePlatform#initializePlatformOperators. 

This can easily be fixed by providing the appropriate TODAY operator in Oracle9Platform#initializePlatformOperators to use the correct function to return the timestamp. As has been done for Oracle9Platform#getTimestampQuery.
Comment 1 Eclipse Webmaster CLA 2022-06-09 10:06:17 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink