SSH2添加信息时出错
我想向question表格中添加新question,提交表单后,后台有正常提示Addnewquestion:bean.Question@d9da94Hibernate:i...
我想向question表格中添加新question,提交表单后,后台有正常提示
Add new question: bean.Question@d9da94
Hibernate: insert into project.question (quesContent, delete, lock) values (?, ?, ?)
但是 前台就报错了
dao.InvalidDataAccessResourceUsageException: could not insert: [bean.Question]; SQL [insert into project.question (quesContent, delete, lock) values (?, ?, ?)]; nested exception is org.hibernate.exception.SQLGrammarException: could not insert: [bean.Question]
求教 这是什么问题?
这个表格的删除功能,还有其它表格的增删改功能都正常
org.springframework.orm.hibernate3.SessionFactoryUtils.convertHibernateAccessException(SessionFactoryUtils.java:629)
org.springframework.orm.hibernate3.HibernateAccessor.convertHibernateAccessException(HibernateAccessor.java:412)
org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:411)
org.springframework.orm.hibernate3.HibernateTemplate.executeWithNativeSession(HibernateTemplate.java:374)
org.springframework.orm.hibernate3.HibernateTemplate.save(HibernateTemplate.java:683)
dao.impl.QuestionDaoImpl.addQuestion(QuestionDaoImpl.java:35)
service.impl.QuestionServiceImple.addQuestion(QuestionServiceImple.java:35)
action.QuestionAction.addQuestion(QuestionAction.java:30)
root cause
org.hibernate.exception.SQLGrammarException: could not insert: [bean.Question]
org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:90)
org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66) 展开
Add new question: bean.Question@d9da94
Hibernate: insert into project.question (quesContent, delete, lock) values (?, ?, ?)
但是 前台就报错了
dao.InvalidDataAccessResourceUsageException: could not insert: [bean.Question]; SQL [insert into project.question (quesContent, delete, lock) values (?, ?, ?)]; nested exception is org.hibernate.exception.SQLGrammarException: could not insert: [bean.Question]
求教 这是什么问题?
这个表格的删除功能,还有其它表格的增删改功能都正常
org.springframework.orm.hibernate3.SessionFactoryUtils.convertHibernateAccessException(SessionFactoryUtils.java:629)
org.springframework.orm.hibernate3.HibernateAccessor.convertHibernateAccessException(HibernateAccessor.java:412)
org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:411)
org.springframework.orm.hibernate3.HibernateTemplate.executeWithNativeSession(HibernateTemplate.java:374)
org.springframework.orm.hibernate3.HibernateTemplate.save(HibernateTemplate.java:683)
dao.impl.QuestionDaoImpl.addQuestion(QuestionDaoImpl.java:35)
service.impl.QuestionServiceImple.addQuestion(QuestionServiceImple.java:35)
action.QuestionAction.addQuestion(QuestionAction.java:30)
root cause
org.hibernate.exception.SQLGrammarException: could not insert: [bean.Question]
org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:90)
org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66) 展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询