-->
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: Could not parse mapping document
PostPosted: Wed Apr 03, 2013 4:52 am 
Newbie

Joined: Tue Apr 02, 2013 3:36 am
Posts: 4
Hello,

I'm using Tapestry 5 with Hibernate connected to SQLServer, and I've got the following problem:

https://docs.google.com/file/d/0B0_KI_Lyv76_TEw4Nm1YOXczRkU/edit?usp=sharing

This is the mapping file:
Code:
<?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="/tutorial1/src/main/java/com/example/tutorial/entities/Address" table="address">
         <id name="iD">   
            <column name="id"/>
            <generator class="increment"/>
         </id>
      <property name="honorific" type="java.lang.String"/>
      <property name="firstName" type="java.lang.String"/>
      <property name="lastName" type="java.lang.String"/>
      <property name="street1" type="java.lang.String"/>
      <property name="street2" type="java.lang.String"/>
      <property name="city" type="java.lang.String"/>
      <property name="state" type="java.lang.String"/>
      <property name="zip" type="java.lang.String"/>
      <property name="email" type="java.lang.String"/>
      <property name="phone" type="java.lang.Integer"/>      
   </class>
</hibernate-mapping>


and this is the hibernate.cfg.xml:

Code:
<!DOCTYPE hibernate-configuration PUBLIC
        "-//Hibernate/Hibernate Configuration DTD 3.0//EN"
        "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
    <session-factory>
        <property name="hibernate.connection.driver_class">com.microsoft.sqlserver.jdbc.SQLServerDriver</property>
        <property name="hibernate.connection.url">jdbc:sqlserver://localhost/testdb;integratedSecurity=true</property>
        <property name="hibernate.dialect">org.hibernate.dialect.SQLServerDialect</property>
        <property name="hibernate.connection.username"></property>
        <property name="hibernate.connection.password"></property>
        <property name="hbm2ddl.auto">update</property>
        <property name="hibernate.show_sql">true</property>
        <property name="hibernate.format_sql">true</property>
        <!-- Mapping file:  -->
        <mapping resource="com/example/tutorial/mapping/hibernate.hbm.xml" />
    </session-factory>
</hibernate-configuration>


Any suggestions are welcome and greatly appreciated.


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.