The content of element type "session-factory" must match "(property*,mapping*,(class-cache| collect
2015-03-13 16:30
1596 查看
配置hibernate.cfg.xml时提示The content of element type "session-factory" must match "(property*,mapping*,(class-cache| collection-cache)*,event*,listener*)".的错。
提示先配置property*元素,再配置mapping*元素,依次类推,仔细检查下看看你的程序中是否存在配置顺序错乱的情况。
只是因为在
<hibernate-configuration>
<session-factory>
</session-factory>
</hibernate-configuration>
之间存在元素配置顺序的错误,只需要按提示将顺序调整正确即可。
提示先配置property*元素,再配置mapping*元素,依次类推,仔细检查下看看你的程序中是否存在配置顺序错乱的情况。
只是因为在
<hibernate-configuration>
<session-factory>
</session-factory>
</hibernate-configuration>
之间存在元素配置顺序的错误,只需要按提示将顺序调整正确即可。
相关文章推荐
- The content of element type "session-factory" must match "(property*,mapping*,(class-cache| collect
- hibernate The content of element type "session-factory" must match "(property*,mapping*,(class-cache
- The content of element type "session-factory" must match "(property*,mapping*,(class-cache|collectio
- The content of element type "session-factory" must match "(property*,mapping*,(class-cache|collectio
- The content of element type "session-factory" must match "(property*,mapping*,(class-cache| c
- The content of element type "session-factory" must match "(property*,mapping*,(class-cache|collectio
- The content of element type "session-factory" must match "(property*,mapping*,(class-cache|collectio
- Hibernate配置文件报错:The content of element type "session-factory" must match "(property*,mapping*,(c
- The content of element type "hibernate-configuration" must match "(session-factory,security?)
- The content of element type "class" must match "(meta*,subselect?,cache?,synchronize*,comment?,tupli
- The content of element type "class" must match "(meta*,subselect?,cache?,synchronize*,comment?,tupli
- hibernate:newclass.hbm.xml文件错误(the content of element type "class" must match "(meta*,column*,type?generator?...)
- hibernate.cfg.xml出错:The content of element type "property" must match "(meta*,(column|formula)*
- "org.xml.sax.SAXParseException: The content of element type "class" must match" 异常解决
- The content of element type "mapper" must match "(cache-ref|cache|resultMap*|parameterMap*|sql*| ins
- The content of element type "sqlMapConfig" is incomplete, it must match "(properties?,settings?,resu
- The content of element type "web-app" must match "(icon?,display-name?,description?,distributable?,c
- hibernate.cfg.xml出错:The content of element type "property" must match "(meta*,(column|formula)*
- struts2---The content of element type "package" must match "(result-types?,interceptors?,default-int
- The content of element type "resultMap" must match "(constructor?,id*,result*,association*,collectio