annotation « Insert « JPA Q&A

1. How can I insert a record in join table of a many to many hibernate annotation?

I have many to many relationship between two table and generate new join table in hibernate now how can I insert a record in join table by updatation of both table say two ...

2. Hibernate annotation unnecessary delete and insert

I have a class A which has set of class B. class A and class B has their own table. When i insert class A it also insert class B. When i ...

3. Hibernate 3.5 annotation problem. not able to insert?

HI, I have two classes SeedUrl and Content. where the SeedUrl id is the foreign key of Content.. I am doing the following :

public class SeedUrl {


4. generate DDL from JPA annotations

I'm trying to generate a DDL from a set of JPA-annotated classes using the hbm2ddl goal of the hibernate3-maven-plugin. I've configured the following in my pom.xml


5. generate DDL from JPA annotations

I have the following classes in my JPA model (getters, setters, and irrelevant fields omitted):

@Entity @Inheritance(strategy = InheritanceType.TABLE_PER_CLASS)
public class Price {

    @ManyToOne(optional = false)