This week's book giveaway is in the Design forum.
We're giving away four copies of Building Microservices and have Sam Newman on-line!
See this thread for details.
The moose likes Object Relational Mapping and the fly likes Could not parse mapping document from resource register.hbm.xml Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Building Microservices this week in the Design forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Could not parse mapping document from resource register.hbm.xml" Watch "Could not parse mapping document from resource register.hbm.xml" New topic
Author

Could not parse mapping document from resource register.hbm.xml

venkataswamy sonti
Greenhorn

Joined: Apr 14, 2012
Posts: 7
Hi I am not able to find the why that exception occurs.

My register.hbm.xml as follows

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN" "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
<hibernate-mapping>
<class name="RegisterPojo" table="REGISTRATION">
<id name="registerId" column="registerid">
<generator class="sequence"/>
</id>
<property name="name" column="name" not-null="true"/>
<property name="address" column="address" not-null="true"/>
<property name="phone" column="phone" not-null="true"/>
<property name="email" column="email" not-null="true"/>
<property name="userName" column="userName" not-null="true"/>
<property name="password" column="password" not-null="true"/>
<property name="cpassword" column="cpassword" not-null="true"/>
</class>
</hibernate-mapping>



Could you please help me on this. Thank you in advance.
Anurag Verma
Ranch Hand

Joined: Mar 30, 2012
Posts: 128

Is your RegisterPojo class inside some package? If no, then recommendation is put it inside some package & update your hbm file as per that. If you already have it, then you missed to mention the package name in your hbm file.
venkataswamy sonti
Greenhorn

Joined: Apr 14, 2012
Posts: 7
Thank you.. yes, i forgot the mentioned the package name infront of the form name in xml file. now its working..
 
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
 
subject: Could not parse mapping document from resource register.hbm.xml
 
jQuery in Action, 3rd edition