Hi,

I am trying to make a simple date comparison in JBoss 3.2.5 but I always have parsing 
errors.
I am using a mySQL database and java.util.Date java type with the default jboss data 
mapping.

Here is my query :
SELECT OBJECT(dt) FROM DT_REGISTRY as dt WHERE dt.creationTime + dt.timeoutDelay > ?1

(the parameter ?1 is initialized to the current date)

and the error message :

11:59:56,251 INFO  [STDOUT] org.jboss.ejb.plugins.cmp.ejbql.ParseException: 
Encountered "+" at line 1, column 64.
Was expecting one of:
    "BETWEEN" ...
    "NOT" ...
    "IN" ...
    "=" ...
    ">" ...
    ">=" ...
    "<" ...
    "<=" ...
    "<>" ...
    

If i don't use arithmetic, it works but this is not what I want ...

SELECT OBJECT(dt) FROM DT_REGISTRY as dt WHERE dt.creationTime > ?1 works fine.

I tried it in ejb ql or in jboss ql: same error.

Any ideas ?
Thanks,
- Papps


View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3850743#3850743

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3850743


-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to