在运行时抛出异常,提示:
Unable to perform unmarshalling at line number 47 and column 23 in RESOURCE hibernate.cfg.xml. Message: cvc-complex-type.2.3: 元素 'session-factory' 必须不含字符 [子级], 因为该类型的内容类型为“仅元素”。
错误原因:bibernate.cfg.xml文件里存在特殊字符,把里面的除代码外的字符删掉即可运行(包括<!-- -->)注释删掉以后,正常运行