Top "Hibernate" questions

Hibernate is an object-relational mapping (ORM) library for the Java language enabling developers to utilize POJO-style domain models in their applications in ways extending well beyond Object/Relational Mapping.

Spring Data JPA map the native query result to Non-Entity POJO

I have a Spring Data repository method with a native query @Query(value = "SELECT g.*, gm.* FROM group g LEFT …

spring hibernate jpa spring-data pojo
Hibernate SessionFactory vs. JPA EntityManagerFactory

I am new to Hibernate and I'm not sure whether to use a Hibernate SessionFactory or a JPA EntityManagerFactory to …

java hibernate jpa sessionfactory hibernate-entitymanager
Spring transaction REQUIRED vs REQUIRES_NEW : Rollback Transaction

I have a method that has the propagation = Propagation.REQUIRES_NEW transactional property: @Transactional(propagation = Propagation.REQUIRES_NEW) public void …

java spring hibernate transactions spring-transactions
Hibernate Criteria Restrictions AND / OR combination

How would I achieve this using Hibernate Restrictions? (((A='X') and (B in('X',Y))) or ((A='Y') and (B=…

hibernate criteria hibernate-criteria restrictions
Spring Boot + JPA : Column name annotation ignored

I have a Spring Boot application with dependency spring-boot-starter-data-jpa. My entity class has a column annotation with a column name. …

java hibernate jpa spring-boot
Hibernate Union alternatives

What alternatives do I have to implement a union query using hibernate? I know hibernate does not support union queries …

java sql hibernate union
Hibernate JPA Sequence (non-Id)

Is it possible to use a DB sequence for some column that is not the identifier/is not part of …

java hibernate jpa sequence
How can I mark a foreign key constraint using Hibernate annotations?

I am trying to use Hibernate annotation for writing a model class for my database tables. I have two tables, …

java hibernate hibernate-mapping hibernate-annotations