JPA Cascading

logo

How to Save Child Entities using Hibernate?

One of the most essential concepts in Hibernate is working with parent-child entity relationships, where a parent entity contains references to one or more child entities. To ensure that we are saving/updating the child entities (along with the parent entity), we depend on the correct usage of annotations like @OneToOne, @OneToMany, @ManyToMany, @JoinColumn, and cascade …

Cascade Types in JPA and Hibernate

Learn JPA Cascade Types and how they are related to Hibernate Cascade Types. Learn how to control the orphan removal with an example.

About Us

HowToDoInJava provides tutorials and how-to guides on Java and related technologies.

It also shares the best practices, algorithms & solutions and frequently asked interview questions.