Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » Query error/JPQL Exception
Query error/JPQL Exception [message #958800] Fri, 26 October 2012 08:17 Go to next message
Arnaud Schildknecht is currently offline Arnaud SchildknechtFriend
Messages: 1
Registered: October 2012
Junior Member

I'm using EclipseLink 2.4.0 on a OC4J 10g server and sometimes when the server reboot automatically this error appears :

Caused by: Exception [EclipseLink-0] (Eclipse Persistence Services - 2.4.0.v20120608-r11652): org.eclipse.persistence.exceptions.JPQLException
Exception Description: Syntax error parsing [ SELECT o FROM GesdpCompany o join o.gesdpProgramMembers as gpm where o.companyId = :companyID AND gpm.programMemberId='AP'].
[69, 124] The expression is not a valid conditional expression.
[69, 124]  The expression is invalid, which means it does not follow the JPQL grammar.
        at org.eclipse.persistence.internal.jpa.jpql.HermesParser.buildException(
        at org.eclipse.persistence.internal.jpa.jpql.HermesParser.validate(
        at org.eclipse.persistence.internal.jpa.jpql.HermesParser.populateQueryImp(
        at org.eclipse.persistence.internal.jpa.jpql.HermesParser.buildQuery(
        at org.eclipse.persistence.internal.jpa.EJBQueryImpl.buildEJBQLDatabaseQuery(
        at org.eclipse.persistence.internal.jpa.JPAQuery.processJPQLQuery(
        at org.eclipse.persistence.internal.jpa.JPAQuery.prepare(
        at org.eclipse.persistence.queries.DatabaseQuery.checkPrepare(
        at org.eclipse.persistence.queries.DatabaseQuery.checkPrepare(
        at org.eclipse.persistence.internal.sessions.AbstractSession.processJPAQueries(
        at org.eclipse.persistence.internal.sessions.DatabaseSessionImpl.initializeDescriptors(
        at org.eclipse.persistence.internal.sessions.DatabaseSessionImpl.postConnectDatasource(
        at org.eclipse.persistence.internal.sessions.DatabaseSessionImpl.loginAndDetectDatasource(
        at org.eclipse.persistence.internal.jpa.EntityManagerFactoryProvider.login(
        at org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.deploy(
        ... 83 more

If I reboot manually the server, it works fine.
Is there any options to resolve this please ?

Note : A few month ago I migrate from TopLink to EclipseLink.
Re: Query error/JPQL Exception [message #964748 is a reply to message #958800] Tue, 30 October 2012 19:19 Go to previous message
James Sutherland is currently offline James SutherlandFriend
Messages: 1939
Registered: July 2009
Location: Ottawa, Canada
Senior Member

It could base a spacing issue, try,

gpm.programMemberId = 'AP'

Also, the latest 2.4 patch release may fix the issue.

James : Wiki : Book : Blog : Twitter
Previous Topic:SessionProfiler, count number of queries executed during transaction
Next Topic:Partitioning parallel query execution
Goto Forum:

Current Time: Tue Sep 25 09:51:08 GMT 2018

Powered by FUDForum. Page generated in 0.03835 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top