Skip to Content
avatar image
Former Member

Timestamp comparison with EJB QL

Hi everybody,

I have an entity bean (CPM) that has a timestamp field.

For a finder method I'd like to use the following EJB QL statement:

SELECT OBJECT(p) FROM MySchema AS p WHERE p.myTimestamp >= ?1

Unfortunally I receive an error during deployment from my WAS 700:

Incorrect QL query: SELECT OBJECT(p) FROM MySchema AS p WHERE p.myTimestamp >= ?1, errors: line 1: Comparison '>=' not defined for dependent objects

Has anybody an idea why the timestamp comparison leads to an error. On other J2EE application servers this works without any problems.

Regards,

Markus

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Jan 16, 2007 at 10:13 AM

    Try checking EJB QL 2.1 compatibility in persistent.xml

    You can define CMP field as Long too.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      I opend an OSS message at SAP for this issue.

      The answer was that a comparison of timestamps in EJB QL is not supported by SAP WAS 700 and below.