rg.springframework.orm.hibernate3.HibernateQueryException: CityCityControl is not mapped [from CityCityControl where active='Y' and degree='CITY']; nested exception
CityCityControl找不到映射,原因一般有两个:
1. CityCityControl对应的.hbm.xml映射文件中的 class name找不到,或者table找不到。
[img]http://dl2.iteye.com/upload/attachment/0093/1864/b2ca1572-fcb4-3cfc-aabe-ce2291ca80a2.png[/img]
2.最重要的也是最容易忘记的是,数据源文件映射扫描配置。
[img]http://dl2.iteye.com/upload/attachment/0093/1866/192091ac-08c5-3e19-8b9b-c910b08fd0d2.png[/img]
CityCityControl找不到映射,原因一般有两个:
1. CityCityControl对应的.hbm.xml映射文件中的 class name找不到,或者table找不到。
[img]http://dl2.iteye.com/upload/attachment/0093/1864/b2ca1572-fcb4-3cfc-aabe-ce2291ca80a2.png[/img]
2.最重要的也是最容易忘记的是,数据源文件映射扫描配置。
[img]http://dl2.iteye.com/upload/attachment/0093/1866/192091ac-08c5-3e19-8b9b-c910b08fd0d2.png[/img]