Skip to main content



      Home
Home » Language IDEs » Eclipse Web Tools Platform Project (WTP) » Dali: JPA 2.1 validation mark NamedQuery as error, but the query works(JPA Validation in Dali mark NamedQuery as Error when use javax.persistence.NamedQuery)
Dali: JPA 2.1 validation mark NamedQuery as error, but the query works [message #1795769] Fri, 28 September 2018 05:59
Eclipse UserFriend
I have a Maven jpa 2.1 hibernate project and want to define a NamedQuery in an entity like
"select f from Forest f join fetch f.tree t join fetch t.leaves l where l is not empty"
The query is marked as Error in the form:
- JOIN FETCH expressions cannot be defined with an identification variable.
and
- The collection-valued path 'l IS NOT EMPTY' must resolve to an association field.

When I change the import
import javax.persistence.NamedQuery;
to
import org.hibernate.annotations.NamedQuery;
the strange errors are gone.

I use jee eclipse photon.

Is there a way to disable these wrong error message?

[Updated on: Fri, 28 September 2018 06:01] by Moderator

Previous Topic: Native library path not working in tomcat
Next Topic:Making Jetty work with Wordpress on separate server (? right forum?)
Goto Forum:
  


Current Time: Wed Jul 16 02:39:27 EDT 2025

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

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

Back to the top