query « Eclipse « JPA Q&A

1. EclipseLink: Query to MappedSuperclass fails    stackoverflow.com

My application is a store selling fishes, aquariums etc. I want to get a list of top 10 items among all the items based on sales count. I use the following ...

2. How do I query for only superclass entities in a jpql query?    stackoverflow.com

I have the following entities:

@DiscriminatorColumn(name="orderType", discriminatorType=DiscriminatorType.STRING)
@Table(name = "orders")
public class OrderEntity implements Serializable {
public class RecurringOrderEntity extends OrderEntity{
I can find all the subclasses (RecurringOrderEntity) with the following jpql:
Query q = em.createQuery(

3. How to get JPQL queries autocompolete for me in Eclipse3.5    stackoverflow.com

How to get JPQL queries autocompoleted for me in Eclipse. (note: Idon't want to use thrid party tools, BTW, JBoss Hibernate tools cannot work with me, I think it needs hibernate specific ...

4. jpa avoid query    stackoverflow.com

i have the next class

@Table(name = "table_order")    
public class Order {    
   /** Unique identifier ...

5. JPA 2 query giving strange behavior on OR clause    stackoverflow.com

I have a JPA 2 query that is driving me nuts. A SurveyQuestion may have an Organization. Here's the mapping within SurveyQuestion

@ManyToOne( optional=true )
@JoinColumn( name="organization_key" )
private Organization organization;
Organization has ...

6. JPA: querying FK    stackoverflow.com

I'm using EclipseLink(JPA 2.0) under Netbeans 7.0 with JDK 7. Adding more, this is a JavaSE. I have this tables, Employee and Record where in the relation is Employee(1) --- (*)Records. Adding more ...

7. How to write JPA query with boolean condition    stackoverflow.com

In my project i am using JPA 2.0 with eclipselink inplementation, an I have following problem: I have defined entity with boolean column:

public User {


8. Problem Migrating a ntive query from Hibernate to EclipseLink 2.0    stackoverflow.com

I'll appreciate if anyone can point me to a solution as to why I could be getting the error below in an attempt to execute the following query which caused no ...

9. Is it possible to do a query inside a JPA entity? (EclipseLink, Jersey, Jackson JSON)    stackoverflow.com

I have two entities Task and TaskStatus. A task can have a history of TaskStatuses (1-n). I listed them below (stripped down to remove clutter).

public class Task implements Serializable {

10. How use Hibernate Tools to execute JPQL Queries?    stackoverflow.com

I need to make some tests with JPQL, so I'm trying do that with Hibernate Tools, but when I try open the session factory appears this : Could not locate TransactionManager ...