-->
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.  [ 5 posts ] 
Author Message
 Post subject: Issue during reverse engineering using existing DB schema
PostPosted: Tue Sep 11, 2007 10:37 pm 
Newbie

Joined: Tue Sep 11, 2007 9:52 pm
Posts: 7
I am facing problem while using reverse engineering with exiting DB schema

Version which I am using are
Hibernate Core 3.2.5.ga
HibernateTools-3.2.0.beta9a


Below is the reverse engineering xml,

<hibernate-reverse-engineering>
<schema-selection match-schema="DB_SHM"/>

</hibernate-reverse-engineering>

I tried this using eclipse plugin. I am trying to generate mapping files,config files and domain java files.It generates all files properly for all tables from schema except for one table (PARTY_ROLE). I don't see any error log in the eclipse console during code generation.

PARTY_ROLE table has only two columns and both are part of primary key. This file has one to many relationship with table RELATIONSHIP.
Class files and mapping files for RELATIONSHIP table gets generated properly. Even mapping file for RELATIONSHIP shows relationship for PARTY_ROLE table.


Generated mapping file for RELATIONSHIP table,

<hibernate-mapping>
<class name="com.service.hibernate.Relationship" table="RELATIONSHIP" schema="ODSCUST_OWNER">
<id name="membershipId" type="big_decimal">
<column name="MEMBERSHIP_ID" precision="22" scale="0" />
<generator class="assigned" />
</id>
<many-to-one name="partyRoleByFkRoleTo" class="com.services.hibernate.PartyRole" fetch="select">
<column name="ROLE_ID_TO" precision="22" scale="0" />
<column name="PARTY_ID_TO" precision="22" scale="0" />
</many-to-one>
<many-to-one name="partyRoleByFkRoleFrom" class="com.services.hibernate.PartyRole" fetch="select">
<column name="ROLE_ID_FROM" precision="22" scale="0" />
<column name="PARTY_ID_FROM" precision="22" scale="0" />
</many-to-one>

</class>
</hibernate-mapping>

Could you tell me what is the reason for not generating required files ?


Top
 Profile  
 
 Post subject:
PostPosted: Wed Sep 12, 2007 9:52 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
have you tried with the latest release ?

...if it still is a problem there let me know.

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Wed Sep 12, 2007 1:45 pm 
Newbie

Joined: Tue Sep 11, 2007 9:52 pm
Posts: 7
After copying eclipse plugin from HibernateTools-3.2.0.beta10 it throws ClassNotFound error whenever i try to load any Hibernate views.

I tried restarting eclipse, still the same error.

For example if try to open ReverseEngineering wizard
Plug-in org.hibernate.eclipse.console was unable to load class org.hibernate.eclipse.console.wizards.NewReverseEngineeringFileWizard.
.

I have checked these files are available under <eclipse_home>/plugins/org.hibernate.eclipse.console_3.2.0.beta10/org.hibernate.eclipse.console.jar

Other files are located as below,
<eclipse_home>/plugins/org.hibernate.eclipse.help_3.2.0.beta10
<eclipse_home>/plugins/org.hibernate.eclipse.mapper_3.2.0.beta10
<eclipse_home>/plugins/org.hibernate.eclipse_3.2.0.beta10
<eclipse_home>/plugins/org.jboss.ide.eclipse.freemarker_1.0.0.beta3
<eclipse_home>/plugins/org.hibernate.eclipse.jdt.apt.ui_3.2.0.beta10.jar
<eclipse_home>/plugins/org.hibernate.eclipse.jdt.ui_3.2.0.beta10.jar

feaures folder i have copied as below ,
<eclipse_home>/features/org.hibernate.eclipse.feature_3.2.0.beta10


Top
 Profile  
 
 Post subject:
PostPosted: Wed Sep 12, 2007 3:17 pm 
Newbie

Joined: Tue Sep 11, 2007 9:52 pm
Posts: 7
Even after updating to HibernateTools-3.2.0.beta10 I still have orginal problem - still not generating PARTY_ROLE table. Behaviour is still the same as before.

I am using oracle 9.2 database and thin driver (ojdbc14.jar) I tried using org.hibernate.dialect.Oracle9iDialect and org.hibernate.dialect.Oracle9Dialect - output is same


Top
 Profile  
 
 Post subject:
PostPosted: Thu Sep 13, 2007 2:14 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
add it to jira with the simplest schema and related files so i can reproduce it. thanks.

_________________
Max
Don't forget to rate


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

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.