javax.persistence.PersistenceException: org.hibernate.exception.SQLGrammarException: could not get next sequence value

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

,
Expert tip

Try downgrading PostgresSQL server to 9.5 or update your PostgresSQL driver to 9.4-1211 with the following command: <postgresql.version>9.4.1211</postgresql.version>

Solutions on the web

via hivmr.com by Unknown author, 1 year ago
org.hibernate.exception.DataException: could not insert: [net.mpsolution.model.Usuario]
via https://bugzilla.redhat.com/bugzilla/ by Rajan Timaniya, 1 year ago
org.hibernate.NonUniqueObjectException: a different object with the same identifier value was already associated with the session: [org.rhq.core.domain.content.RepoContentSource#RepoContentSourcePK: repo=[Repo: id=[101], name=[JBoss Patches]]; contentSource=[ContentSource: id=[101], name=[JBoss CSP Patch Feed]]]
via hibernate.org by Unknown author, 1 year ago
org.hibernate.exception.SQLGrammarException: could not get next sequence value
via hibernate.org by Unknown author, 2 years ago
org.hibernate.exception.SQLGrammarException: could not get next sequence value
org.postgresql.util.PSQLException: ERROR: syntax error at or near "call"
at org.apache.tomcat.dbcp.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:92)
at org.hibernate.id.SequenceGenerator.generate(SequenceGenerator.java:98)
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:90)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66)
at org.hibernate.id.SequenceGenerator.generate(SequenceGenerator.java:119)
at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:614)
at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:226)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
at java.lang.Thread.run(Unknown Source)

Users with the same issue

37 times, 1 week ago
3 times, 1 month ago
Once, 2 months ago
Once, 2 months ago
32 times, 2 months ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.