HTTP Status 500 – Request processing failed; nested exception is org.springframework.transaction.TransactionSystemException: Could not roll back Hibernate transaction; nested exception is org.hibernate.TransactionException: rollback failed
↓
root cause
org.springframework.transaction.TransactionSystemException: Could not roll back Hibernate transaction; nested exception is org.hibernate.TransactionException: rollback failed
↓
org.hibernate.TransactionException: unable to rollback against JDBC connection
↓
root cause
java.sql.SQLException: SQL logic error or missing database
SQL语句:select name,phone,idcard,nowlive,ofCompany,stationCode,type,status,certificatecode from(
select p.name,p.phone,p.idcard,p.nowlive,p.ofcompany ,p.stationcode ,p.type,p.status,z.CertificateCode
FROM basicperson p join BasicZhengJ z on p.phone=z.phone)
很简单的子查询,可以在查询分析器正确执行,放入dao实现类运行就报以上错误
求解决!!!
回复讨论(解决方案)
放五一都没个人了??????????????????哎
…. (
select p.name,p.phone,p.idcard,p.nowlive,p.ofcompany ,p.stationcode ,p.type,p.status,z.CertificateCode
FROM basicperson p join BasicZhengJ z on p.phone=z.phone) T
需要指定别名
…. (
select p.name,p.phone,p.idcard,p.nowlive,p.ofcompany ,p.stationcode ,p.type,p.status,z.CertificateCode
FROM basicperson p join BasicZhengJ z on p.phone=z.phone) T
需要指定别名
首先感谢版主的问候,其次,我试了没用,SQL语句没有错
用HQL语法,就可以解决!
解决了!哎,五一都没人呢?
楼主自己怎么解决的给总结一下,也好给别的人一个参考嘛 :)
版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容, 请发送邮件至253000106@qq.com举报,一经查实,本站将立刻删除。
发布者:PHP中文网,转转请注明出处:https://www.chuangxiangniao.com/p/3102207.html