sql « Entity « JPA Q&A





1. Automatically create Entities from database    stackoverflow.com

Is there a way to automatically create javax.persistence.Entity classes from an existing database (or from the SQL statements that created them)? I am just reading through the persistence part of

2. How to make an entity out of a join table without primary key    stackoverflow.com

I'm trying to generate JPA entities out of an existing database having an "interesting" design. Database has a table called UserSet, which can have links to several other UserSets. There is a ...

3. How to choose that which ORM would be feasible for or Application? e.g if we are using Linq then why not hibernate    stackoverflow.com

How to choose that which ORM would be feasible for a web Application? e.g if we are using Linq then why not nhibernate? and Which one is better and why ...

4. Does Hibernate update an entity that has not changed?    stackoverflow.com

Given an unchanged entity, does Hibernate session.update(entity) send an SQL UPDATE statement to the database server? For example, in the following code, does Hibernate ...

5. java.sql.SQLIntegrityConstraintViolationException when updating an entity    stackoverflow.com

I am new to JPA and I am experiencing the following problem, probably due to a not sufficient understanding of cascade and associations? I have two entities which are in a ...

6. Hibernate - native SQL + non-managed entities + collections    stackoverflow.com

This documentation chapter explains how to return non-managed entities for native queries. Is it possible for those entities to have collections of other non-managed entities?

7. Entities with Foreign Key references to phantom tables & entities    stackoverflow.com

I have an existent legacy DDL which I've to map onto JPA. I've already mapped the USERS SQL table to an USERS JPA @Entity.

create table USERS (
  -- a bunch of ...

8. SQL and refrenced entities    forum.hibernate.org

Hibernate version: 3.1 Name and version of the database you are using: Oracle 8 Hi This is a general question Is there a way when I am using SQL to run the queries against the database through Hibernate to make Hibernate fetch the referenced objects without me explicit writing it in the SQL. This problem is extremely obvious when I am ...