"org.hibernate.QueryException: could not resolve property" error when trying to execute a JPA query in JBoss EAP 6

Solution Verified - Updated -

Issue

Found the following error while executing a JPA query on a deployed application:

org.hibernate.QueryException: could not resolve property: 
newProperty of: my.package.MyPOJO 
[SELECT b FROM my.package.MyPOJO b WHERE b.something = :something and b.newProperty = :newProperty ]

Environment

  • Red Hat Jboss Enterprise Application Platform (EAP) 6.x
  • JPA 2

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.