ObjectDB 2.8.7.b08
Our entities are not enhanced and we execute a query "select max(uid) from ModelElementImpl".
In the objectdb.conf the reflection is set to error.
<entities> ... <enhancement agent="false" reflection="error" />
We got following exception after execution of the query:
Caused by: com.objectdb.o.UserException: Unexpected query token 'uid' at com.objectdb.o.TKN.w(TKN.java:802) at com.objectdb.o.QNF.h(QNF.java:446) at com.objectdb.o.QNF.v(QNF.java:171) at com.objectdb.o.QNF.a(QNF.java:1233) at com.objectdb.o.QNF.v(QNF.java:267) at com.objectdb.o.QRC.f(QRC.java:643) at com.objectdb.o.QRC.g(QRC.java:615) at com.objectdb.o.QRC.m(QRC.java:560) at com.objectdb.o.QRC.t(QRC.java:241) at com.objectdb.o.QRC.j(QRC.java:190) at com.objectdb.o.QRM.ZO(QRM.java:273) at com.objectdb.o.MST.ZO(MST.java:1026) at com.objectdb.o.WRA.ZO(WRA.java:313) at com.objectdb.o.WSM.ZO(WSM.java:117) at com.objectdb.o.QRR.k(QRR.java:260) at com.objectdb.o.QRR.i(QRR.java:154) at com.objectdb.jpa.JpaQuery.getSingleResult(JpaQuery.java:760)
I would expect an exception with a message like "the entities are not enhanced ..." instead of the UserException: Unexpected query token 'uid'.
If the entities are enhanced then the query works without exception.