[hibernate-dev] Naming strategies and join tables

Guillaume Smet guillaume.smet at gmail.com
Mon Feb 22 06:10:52 EST 2016


I'm migrating another application to 5.x and have the following issue with
the new naming strategies.

We used EJB3NamingStrategy and are now using
ImplicitNamingStrategy*Legacy*JpaImpl which is advertised as being its

The model is the following:
       > @Entity
          @DiscriminatorValue(value = "ProjetDiffusion")
           public class ProjetDiffusion extends AbstractProjet {
                 @JoinTable(uniqueConstraints = {
@UniqueConstraint(columnNames = { "projetdiffusion_id", "technologies" }) })
                 private List<ProjetTechnologie> technologies =

Before the upgrade to 5, the join table was called
projetdiffusion_technologies and the column was projetdiffusion_id.

After the upgrade to 5, the join table is called
abstractprojet_technologies and the column abstractprojet_id. Thus, we have
an error on the creation of the unique constraint.

Is this change expected?


More information about the hibernate-dev mailing list