-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: [ middlegen ] association
PostPosted: Wed Jul 20, 2005 5:52 pm 
Beginner
Beginner

Joined: Fri Apr 23, 2004 6:39 pm
Posts: 23
Bonjour,

J'essai de générer des fihiers de mapping a partir de mon schema de base de donnée en utilisant middlegen. Il génere bien toute les associations dans le fichier de mapping sauf une association:



Quote:
BUILD FAILED
F:\hibernate-2.1.2\Middlegen-Hibernate-r5\Middlegen-Hibernate-r5\build.xml:149:
java.lang.IllegalArgumentException: There is no column named util in the table named utilisateur2


voici mon script sql :

Quote:
alter table UTILISATEUR2_ROLES drop constraint FK9C293F8DB8D66786;
alter table UTILISATEUR2_ROLES drop constraint FK9C293F8DB8D4FC31;
alter table UTILISATEUR2 drop constraint FK4FCF252F3472F6;
alter table CONNEXIONS drop constraint FKEFD16ECA36F002;
drop table ROLES;
drop table UTILISATEUR2_ROLES;
drop table UTILISATEUR2;
drop table CONNEXIONS;
drop table PERSONNES;
drop sequence hibernate_sequence;
create table ROLES (
idRole INT8 not null,
nom VARCHAR(255),
primary key (idRole)
);
create table UTILISATEUR2_ROLES (
idUser INT8 not null,
idRole INT8 not null,
primary key (idRole, idUser)
);
create table UTILISATEUR2 (
idUser INT8 not null,
login VARCHAR(255),
password VARCHAR(255),
datecm TIMESTAMP,
issuprimable INT4,
pers INT8 not null,
primary key (idUser)
);
create table CONNEXIONS (
idCnx INT8 not null,
dateDeb DATE,
dateFin DATE,
util INT8 not null,
primary key (idCnx)
);
create table PERSONNES (
idPers INT8 not null,
sousclasse CHAR(1) not null,
nom VARCHAR(255),
prenom VARCHAR(255),
codeInterne VARCHAR(255),
societe VARCHAR(255),
primary key (idPers)
);
alter table UTILISATEUR2_ROLES add constraint FK9C293F8DB8D66786 foreign key (idUser) references UTILISATEUR2;
alter table UTILISATEUR2_ROLES add constraint FK9C293F8DB8D4FC31 foreign key (idRole) references ROLES;
alter table UTILISATEUR2 add constraint FK4FCF252F3472F6 foreign key (pers) references PERSONNES;
alter table CONNEXIONS add constraint FKEFD16ECA36F002 foreign key (util) references UTILISATEUR2;
create sequence hibernate_sequence;




Merci


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.