Bon j'ai essayé de faire avec le JoinTable
dans mon entity USER
pas de collection dans JOIN pour les tests, et ma classe JOIN qui n'est pas une entity.
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9 @OneToMany @JoinTable( name="JOIN", joinColumns = { @JoinColumn( name="user_id") }, inverseJoinColumns = @JoinColumn( name="page_id") ) public Collection<PAGE> getListe_PAGE() { return liste_PAGE; }
J'ai l'erreur suivante :
Bon je ne peux pas modifier la BD...
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5 09:52:13,099 ERROR [SchemaUpdate] Unsuccessful: alter table JOIN add constraint FKFD8FAB9D27D5EEFB foreign key (page_id) references PAGE 09:52:13,099 ERROR [SchemaUpdate] ORA-02275: such a referential constraint already exists in the table 09:52:13,139 ERROR [SchemaUpdate] Unsuccessful: alter table JOIN add constraint FKFD8FAB9D8233B843 foreign key (user_id) references USER 09:52:13,139 ERROR [SchemaUpdate] ORA-02275: such a referential constraint already exists in the table
comment faire???
Merci encore fr1man





Répondre avec citation





Partager