org.hibernate.exception.SQLGrammarException: could not insert: [com.exe.hib.bean.Student]

iteye.com | 9 months ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Hibernate保持session时出错(还有控制台显示发送的SQL也显示不了) - ITeye问答

    iteye.com | 9 months ago
    org.hibernate.exception.SQLGrammarException: could not insert: [com.exe.hib.bean.Student]
  2. 0

    Hibernate程序碰到的两个问题 - 孙豪杰的博客 - ITeye技术网站

    iteye.com | 1 year ago
    org.hibernate.exception.SQLGrammarException: could not insert: [cn.deimy.User]
  3. 0

    Getting “java.sql.SQLException: No value specified for parameter” for a @GeneratedValue field - widecodes.com

    widecodes.com | 2 years ago
    javax.persistence.PersistenceException: org.hibernate.exception.SQLGrammarException: could not insert: [com.evolok.idm.core.domain.DeviceHistory]
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Hibernate3.2.4で@GeneratedValueが効かない - Be an Idealistic Realist

    ne.jp | 2 years ago
    javax.persistence.PersistenceException: org.hibernate.exception.SQLGrammarException: could not insert: [jp.objectfanatics.example.UserImpl]
  6. 0

    Problem with Enums

    Coderanch | 9 years ago | Ra Carter
    javax.persistence.PersistenceException: org.hibernate.exception.SQLGrammarException: could not insert: [org.acme.Anvil]

  1. Hronom 1 times, last 4 months ago
  2. kid 2 times, last 6 months ago
  3. kuldeep 4 times, last 7 months ago
  4. mortalman7 1 times, last 10 months ago
32 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.sql.SQLException

    You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '.stu (stu_name, stu_sex, stu_age, stu_address, stu_description) values ('a', '?'' at line 1

    at com.mysql.jdbc.MysqlIO.checkErrorPacket()
  2. MySQL jdbc
    PreparedStatement.executeUpdate
    1. com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2926)
    2. com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
    3. com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1666)
    4. com.mysql.jdbc.Connection.execSQL(Connection.java:2978)
    5. com.mysql.jdbc.Connection.execSQL(Connection.java:2902)
    6. com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:933)
    7. com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1162)
    8. com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1079)
    9. com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1064)
    9 frames
  3. Hibernate
    AbstractEntityPersister.insert
    1. org.hibernate.id.IdentityGenerator$GetGeneratedKeysDelegate.executeAndExtract(IdentityGenerator.java:73)
    2. org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:33)
    3. org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2154)
    4. org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2634)
    4 frames
  4. Hibernate
    EntityIdentityInsertAction.execute
    1. org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentityInsertAction.java:48)
    1 frame
  5. Hibernate
    ActionQueue.execute
    1. org.hibernate.engine.ActionQueue.execute(ActionQueue.java:248)
    1 frame
  6. Hibernate
    SessionImpl.save
    1. org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:298)
    2. org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:181)
    3. org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:107)
    4. org.hibernate.event.def.DefaultSaveOrUpdateEventListener.saveWithGeneratedOrRequestedId(DefaultSaveOrUpdateEventListener.java:187)
    5. org.hibernate.event.def.DefaultSaveEventListener.saveWithGeneratedOrRequestedId(DefaultSaveEventListener.java:33)
    6. org.hibernate.event.def.DefaultSaveOrUpdateEventListener.entityIsTransient(DefaultSaveOrUpdateEventListener.java:172)
    7. org.hibernate.event.def.DefaultSaveEventListener.performSaveOrUpdate(DefaultSaveEventListener.java:27)
    8. org.hibernate.event.def.DefaultSaveOrUpdateEventListener.onSaveOrUpdate(DefaultSaveOrUpdateEventListener.java:70)
    9. org.hibernate.impl.SessionImpl.fireSave(SessionImpl.java:535)
    10. org.hibernate.impl.SessionImpl.save(SessionImpl.java:523)
    11. org.hibernate.impl.SessionImpl.save(SessionImpl.java:519)
    11 frames
  7. com.exe.hib
    BM.main
    1. com.exe.hib.daoImpl.StudentDaoImpl.createStu(StudentDaoImpl.java:30)
    2. com.exe.hib.bussinessManage.BM.main(BM.java:22)
    2 frames