IDEA中写MyBatis的xml配置文件编译报错的坑 说明:用IDEA编译工具在项目中使用Mybatis框架,编写mybatis-config.xml和Mapper.xml配置文件时,编译项目出现错误,错误提示为: xml中1字节的UTF-8序列的字节1无效 The cause of this is a file that is not UTF-8 is being parsed as UTF-8. It is likely that the parser is encountering a
1....identifier of an instance of org.szgzw.ent.profile.baseinfo.enterprise.EnterpriseEntity was altered from 2c90e4da49514c750149515eb56f0003 to undefined; nested exception is org.hibernate.HibernateException: identifier of an instance of org.szgzw.
错误如下: Server Error in '/' Application. 传入字典的模型项的类型为“System.Collections.Generic.List`1[MvcTest.Models.Score]”,但此字典需要类型“MvcTest.Models.Score”的模型项. 出现以上错误的原因是: 从Controls生成View的时候,ReturnView(query.tolist())传递给View的是一个集合,但是View中需要的是Score单个对象而不是Score的List集