Hi,
I'm trying to execute the following query, and I'm having some problems.
...
sql = new StringBuffer();
sql.append("select object (o) from br.com.synchro.sfisc.db.SynUsuario o ");
sql.append("where o.dhInclusao > 01/01/2004 ");
cbf = CBFacadeSyn.getInstance().getCBFacadeInstance();
param = new Vector();
Vector v = cbf.executeQLQuery(sql.toString(), param);
This code results in the following error:
thought.CocoBase.EJBQLCompileException: [1,69] - Type of map field 'DH_INCLUSAO' is not compatible with NUMERIC
thought.CocoBase.EJBQLQuery.compile(EJBQLQuery.java:105)
thought.CocoBase.CBFacadeLocal.executeQLQuery(CBFacadeLocal.java:600)
br.com.synchro.sfisc.security.Login.authenticate(Login.java:161)
br.com.synchro.security.AuthenticateFilter.doLogin(AuthenticateFilter.java:148)
br.com.synchro.security.AuthenticateFilter.doFilter(AuthenticateFilter.java:97)
If a I put the date between '', the error changes to:
thought.CocoBase.EJBQLCompileException: [1,69] - Type of map field 'DH_INCLUSAO' is not compatible with STRING
The field DH_INCLUSAO is a Timestamp in my Map.
Wath is wrong whit this code?? There's some limitation in EJB Compiler??
Thanks
Fernando Cesar.
|