-->
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.  [ 2 posts ] 
Author Message
 Post subject: Problem with Artifact Generation & Mapping documents
PostPosted: Thu Apr 21, 2005 4:11 pm 
Newbie

Joined: Thu Apr 21, 2005 3:44 pm
Posts: 1
Using Hibernate version:3.0
Problem with Artifact Generation & Mapping documents:
I am a hibernate new user, so help me please!!!

I am using the Hibernate 3.0.1, Eclipse 3.1.M6 width jboss Eclipse IDE 1.5.M1-hibernate-tools and Oracle 9i on Windows XP PRO.
My goal is to create Hibernate Artifacts from my Oracle 9i database, using "Reverse Engineer from JDBC Connection" and "Generate domain code."
Here is my Hibernate.properties file: ...
property name="hibernate.connection.username">user
property name="hibernate.connection.password">***
property name="hibernate.dialect">org.hibernate.dialect.Oracle9Dialect property name="hibernate.connection.url">jdbc:oracle:thin:@IP:1521:company
property name="hibernate.connection.driver_class">oracle.jdbc.driver.OracleDriver
...
I make the console width de hibernate.cfg.xml and i have included the jar of oracle jdbc (ojdbc14.jar and nls...)
When i try to generate the mapping classes i get the following error:
"Error under artifact generation
Reason: org.hibernate.Mappingexception:Could not configure datastore from file :
C:\programfiles\documentsand settings\………..\container.hbm.xml
My Container.hbm.xml looks like this
<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN" "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd" >
<hibernate-mapping>
<class name="com.cms.domain.Container" table="TBL_CONTAINER">
<id name="id" type="long" column="CONTAINER_NO">
<meta attribute="finder-method">findById</meta>
<generator class="sequence">
<param name="sequence">SQ_CONTAINER_NO</param>
</generator>
</id>
<many-to-one name="category" class="com.vai.cms.domain.Category">
<meta attribute="finder-method">findByCategory</meta>
<column name="FK_CATEGORY_NO" not-null="true"/>
</many-to-one>
"C:/Documents and Settings/user /Sandbox/src/com/cms/xml/hibernate/maps/Category.hbm.xml"
<property name="referenceId" type="string" column="REFERENCE_ID" length="127">
<meta attribute="finder-method">findByReferenceId</meta>
</property>
<property name="name" type="string" column="NAME" length="127"/>
<set name="contained" inverse="true" lazy="true" cascade="save-update">
<key column="FK_CONTAINER_CONTAINER_NO"/>
<one-to-many class="com.cms.domain.Container"/>
</set>
</class>
</hibernate-mapping>
Please help.
[/b]


Top
 Profile  
 
 Post subject: same problem, with HSQL instead.
PostPosted: Fri Apr 29, 2005 5:00 pm 
Newbie

Joined: Sun Apr 24, 2005 11:43 pm
Posts: 8
I've got the same problem the only difference being hsql is my database.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 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.