NamedQuery « Entity « JPA Q&A





1. Why can't the meta character * be used in NamedQuery within an entity in JPA?    stackoverflow.com

I'm trying to use the following NamedQuery in my entity class BrandMstr.

@NamedQuery(name = "BrandMstr.findAllBrands", query = "SELECT * FROM BrandMstr")
It throws an exception javax.ejb.EJBException with a long stack trace indicating that ...

3. JPA NamedQuery does not pick up changes to modified Entity    forum.hibernate.org

I am using JBoss 4.2.3 and Hibernate 3.2.6. I have a method that retrieves Entities using a NamedQuery. I update a value of each entity and then run another named query (in the same method and Transaction) filtering by the old value and it returns the same Entities as if I had not changed them. I understand that the EntityManager needs ...