空指针
程序员文章站
2022-07-13 23:35:40
...
session.close();报空指针一班是配置文件写错了,或者basedao写错
<?xml version="1.0" encoding="UTF-8" ?> <environment id="development">
<transactionManager type="JDBC">
</transactionManager>
<dataSource type="POOLED">
<property name="driver" value="${driver}"/>
<property name="url" value="${url}"/>
<property name="username" value="${user}"/>
<property name="password" value="${password}"/>
</dataSource>
</environment>
</environments>
<mappers>
<package name="cn.smbms.dao.provider"/>
</mappers>
("cn.smbms.dao.provider.ProviderDao这里不要用斜杠*)
<select id="getProviderList" resultType="Provider">
select * from smbms_provider
</select>
上一篇: C++关键字解析
下一篇: exit(0)和exit(1)