Please can someone explain me this syntax error?
Thanks
| 125 [main] ERROR org.hibernate.util.XMLHelper - Error parsing XML:
hibernate.cfg.xml(3) A pseudo attribute name is expected.
| #### Error Creating HibernateSessionFactory ####
| org.hibernate.HibernateException: Could not parse configuration: hibernate.cfg.xml
| at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1376)
| at org.hibernate.cfg.Configuration.configure(Configuration.java:1310)
| at
de.laliluna.hibernate.InitSessionFactory.initSessionFactory(InitSessionFactory.java:63)
| at de.laliluna.hibernate.InitSessionFactory.getInstance(InitSessionFactory.java:39)
| at de.laliluna.example.TestClient.createHoney(TestClient.java:82)
| at de.laliluna.example.TestClient.main(TestClient.java:34)
| Caused by: org.dom4j.DocumentException: Error on line 3 of document : A pseudo
attribute name is expected. Nested exception: A pseudo attribute name is expected.
| at org.dom4j.io.SAXReader.read(SAXReader.java:482)
| at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1366)
| ... 5 more
| Exception in thread "main" org.hibernate.HibernateException: Could not
initalize the Hibernate configuation
| at
de.laliluna.hibernate.InitSessionFactory.initSessionFactory(InitSessionFactory.java:78)
| at de.laliluna.hibernate.InitSessionFactory.getInstance(InitSessionFactory.java:39)
| at de.laliluna.example.TestClient.createHoney(TestClient.java:82)
| at de.laliluna.example.TestClient.main(TestClient.java:34)
|
The xaml file should be correct
| <?xml version='1.0' encoding="UTF-8'?>
|
| <!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="connection.url">jdbc:mysql://localhost/firsthibernate</property>
| <property name="connection.username">firsthibernate</property>
| <property
name="connection.driver_class">com.mysql.jdbc.Driver</property>
| <property
name="dialect">org.hibernate.dialect.MySQLDialect</property>
| <property name="connection.password"></property>
| <property
name="transaction.factory_class">org.hibernate.transaction.JDBCTranscationFactory</property>
| <property
name="current_session_context_class">thread</property>
| <property name="hibernat.show_sql">true</property>
|
| <!-- mapping files -->
| <mapping resource="de/laliluna/example/Honey.hbm.xml" />
|
| </session-factory>
|
| </hibernate-configuration>
|
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3995006#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...