
eclipse中的问题
帮忙看一下哪里出错log4j:WARNNoappenderscouldbefoundforlogger(org.hibernate.cfg.Environment).lo...
帮忙看一下哪里出错
log4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment).
log4j:WARN Please initialize the log4j system properly.
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 org.hibernate.cfg.Configuration.configure(Configuration.java:1296)
at ch03.hibernate.Test.main(Test.java:14)
Caused by: org.dom4j.DocumentException: Error on line 2 of document : The document type declaration for root element type "hibernate-configuration" must end with '>'. Nested exception: The document type declaration for root element type "hibernate-configuration" must end with '>'.
at org.dom4j.io.SAXReader.read(SAXReader.java:482)
at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1366)
... 3 more 展开
log4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment).
log4j:WARN Please initialize the log4j system properly.
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 org.hibernate.cfg.Configuration.configure(Configuration.java:1296)
at ch03.hibernate.Test.main(Test.java:14)
Caused by: org.dom4j.DocumentException: Error on line 2 of document : The document type declaration for root element type "hibernate-configuration" must end with '>'. Nested exception: The document type declaration for root element type "hibernate-configuration" must end with '>'.
at org.dom4j.io.SAXReader.read(SAXReader.java:482)
at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1366)
... 3 more 展开
2个回答
展开全部
configuration" must end with '>'.
hbm.cfg.xml文件里出错了。没 配置对。少个 '>'.
hbm.cfg.xml文件里出错了。没 配置对。少个 '>'.
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询