org.springframework.dao.DataIntegrityViolationException: (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.BatchUpdateException: Duplicate entry '32769' for key 1 java.sql.BatchUpdateException: Duplicate entry '32769' for key 1

JIRA | Tom Moore | 5 years ago
  1. 0

    I've followed all the instructions to the letter on http://confluence.atlassian.com/display/CONFEXT/Scripting+and+External+Content+Macros, including installing every single jar plugin and option idenfied in the instructions. However, starting confluence shows the scripting plugin to be disabled, with the following errors: There were errors loading this plugin. There is more information in the logs. groovy Macro to execute a groovy script into a Confluence page Error: There was a problem loading the descriptor for module 'macro' in plugin 'Scripting Plugin' jython Macro to execute a Jython script into a Confluence page xslt Macro to transfer a Xml into confluence page by XSLT sql Macro to execute Sql Statements producing a table. I have the following java errors in my catalina.out file: 2006-05-02 14:03:41,336 ERROR [atlassian.plugin.loaders.AbstractXmlPluginLoader] createModuleDescriptor There were problems loading the module 'macro'. The module and its plugin have been disabled. 2006-05-02 14:03:41,339 ERROR [atlassian.plugin.loaders.AbstractXmlPluginLoader] createModuleDescriptor There was a problem loading the descriptor for module 'macro' in plugin 'Scripting Plugin' com.atlassian.plugin.PluginParseException: Error retrieving dependency of class: com.TAP.confluence.macros.script.GroovyMacro. Missing class: groovy/lang/Binding 2006-05-02 14:03:41,920 ERROR [atlassian.plugin.loaders.AbstractXmlPluginLoader] configurePlugin There were errors loading the plugin 'Scripting Plugin'. The plugin has been disabled. 2006-05-02 14:03:43,862 FATAL [atlassian.confluence.plugin.ConfluencePluginManager] onApplicationEvent Error initialising plugin manager: Duplicate plugin key found: 'com.TAP.confluence.macros.SHAI' com.atlassian.plugin.PluginParseException: Duplicate plugin key found: 'com.TAP.confluence.macros.SHAI' at com.atlassian.plugin.DefaultPluginManager.addPlugin(DefaultPluginManager.java:118) at com.atlassian.confluence.plugin.ConfluencePluginManager.addPlugin(ConfluencePluginManager.java:115) at com.atlassian.plugin.DefaultPluginManager.init(DefaultPluginManager.java:49) at com.atlassian.confluence.plugin.ConfluencePluginManager.onApplicationEvent(ConfluencePluginManager.java:62) at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:68) etc... and 2006-05-02 14:07:23,424 ERROR [sf.hibernate.util.JDBCExceptionReporter] logExceptions Duplicate entry '32769' for key 1 2006-05-02 14:07:23,424 ERROR [sf.hibernate.util.JDBCExceptionReporter] logExceptions Duplicate entry '32769' for key 1 2006-05-02 14:07:23,429 ERROR [sf.hibernate.util.JDBCExceptionReporter] logExceptions Duplicate entry '32769' for key 1 2006-05-02 14:07:23,429 ERROR [sf.hibernate.util.JDBCExceptionReporter] logExceptions Duplicate entry '32769' for key 1 2006-05-02 14:07:23,431 ERROR [sf.hibernate.impl.SessionImpl] execute Could not synchronize database state with session 2006-05-02 14:07:23,431 ERROR [sf.hibernate.impl.SessionImpl] execute Could not synchronize database state with session 2006-05-02 14:07:23,434 ERROR [atlassian.confluence.util.XWorkTransactionInterceptor] onThrowable Invoking rollback for transaction on action '/admin/users/docreateuser.action (CreateUserAction.execute())' due to throwable: org.springframework.dao.DataIntegrityViolationException: (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.BatchUpdateException: Duplicate entry '32769' for key 1 org.springframework.dao.DataIntegrityViolationException: (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.BatchUpdateException: Duplicate entry '32769' for key 1 java.sql.BatchUpdateException: Duplicate entry '32769' for key 1 at com.mysql.jdbc.ServerPreparedStatement.executeBatch(ServerPreparedStatement.java:647) at com.mchange.v2.c3p0.impl.NewProxyPreparedStatement.executeBatch(NewProxyPreparedStatement.java:1722) at net.sf.hibernate.impl.BatchingBatcher.doExecuteBatch(BatchingBatcher.java:54) at net.sf.hibernate.impl.BatcherImpl.executeBatch(BatcherImpl.java:128) at net.sf.hibernate.impl.SessionImpl.executeAll(SessionImpl.java:2438) etc.... and 2006-05-02 14:07:23,442 ERROR [opensymphony.webwork.dispatcher.ServletDispatcher] serviceAction Could not execute action org.springframework.dao.DataIntegrityViolationException: (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.BatchUpdateException: Duplicate entry '32769' for key 1 java.sql.BatchUpdateException: Duplicate entry '32769' for key 1 at com.mysql.jdbc.ServerPreparedStatement.executeBatch(ServerPreparedStatement.java:647) at com.mchange.v2.c3p0.impl.NewProxyPreparedStatement.executeBatch(NewProxyPreparedStatement.java:1722) at net.sf.hibernate.impl.BatchingBatcher.doExecuteBatch(BatchingBatcher.java:54) at net.sf.hibernate.impl.BatcherImpl.executeBatch(BatcherImpl.java:128) at net.sf.hibernate.impl.SessionImpl.executeAll(SessionImpl.java:2438) at net.sf.hibernate.impl.SessionImpl.execute(SessionImpl.java:2392) etc... Any help would be appreciated, as my team really wants the excel plugin :)

    JIRA | 5 years ago | Tom Moore
    org.springframework.dao.DataIntegrityViolationException: (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.BatchUpdateException: Duplicate entry '32769' for key 1 java.sql.BatchUpdateException: Duplicate entry '32769' for key 1
  2. 0

    [CONF-6092] Cannot create new user due to primary key violation or unique constraint error - Atlassian JIRA

    atlassian.com | 11 months ago
    org.springframework.dao.DataIntegrityViolationException: (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.BatchUpdateException: Duplicate entry '1' for key 1
  3. 0

    [CONF-6092] Cannot create new user due to primary key violation or unique constraint error - Atlassian JIRA

    atlassian.com | 1 year ago
    org.springframework.dao.DataIntegrityViolationException: (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.BatchUpdateException: Duplicate entry '1' for key 1
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Here are the exceptions from various databases: Oracle: org.springframework.dao.DataIntegrityViolationException: (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.BatchUpdateException: ORA-00001: unique constraint (CWK.SYS_C002106) violated at org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.translate(SQLStateSQLExceptionTranslator.java:88) caused by: java.sql.BatchUpdateException: ORA-00001: unique constraint (CWK.SYS_C002106) violated at oracle.jdbc.driver.DatabaseError.throwBatchUpdateException(DatabaseError.java:367) MS SQL Server: org.springframework.dao.DataIntegrityViolationException: (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.SQLException: Violation of PRIMARY KEY constraint 'PK__os_user__5070F446'. Cannot insert duplicate key in object 'os_user'. at org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.translate(SQLStateSQLExceptionTranslator.java:88) caused by: java.sql.SQLException: Violation of PRIMARY KEY constraint 'PK__os_user__5070F446'. Cannot insert duplicate key in object 'os_user'. at net.sourceforge.jtds.jdbc.SQLDiagnostic.addDiagnostic(SQLDiagnostic.java:365) MySQL: org.springframework.dao.DataIntegrityViolationException: (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.BatchUpdateException: Duplicate entry '1' for key 1 at org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.translate(SQLStateSQLExceptionTranslator.java:88) caused by: java.sql.BatchUpdateException: Duplicate entry '1' for key 1 at com.mysql.jdbc.ServerPreparedStatement.executeBatch(ServerPreparedStatement.java:647)

    Atlassian JIRA | 1 decade ago | Dave Loeng [Atlassian]
    org.springframework.dao.DataIntegrityViolationException: (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.BatchUpdateException: Duplicate entry '1' for key 1

    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. org.springframework.dao.DataIntegrityViolationException

      (Hibernate operation): data integrity violated by SQL ''; nested exception is java.sql.BatchUpdateException: Duplicate entry '32769' for key 1 java.sql.BatchUpdateException: Duplicate entry '32769' for key 1

      at com.mysql.jdbc.ServerPreparedStatement.executeBatch()
    2. MySQL jdbc
      ServerPreparedStatement.executeBatch
      1. com.mysql.jdbc.ServerPreparedStatement.executeBatch(ServerPreparedStatement.java:647)
      1 frame
    3. c3p0:JDBC DataSources/Resource Pools
      NewProxyPreparedStatement.executeBatch
      1. com.mchange.v2.c3p0.impl.NewProxyPreparedStatement.executeBatch(NewProxyPreparedStatement.java:1722)
      1 frame
    4. net.sf.hibernate
      SessionImpl.execute
      1. net.sf.hibernate.impl.BatchingBatcher.doExecuteBatch(BatchingBatcher.java:54)
      2. net.sf.hibernate.impl.BatcherImpl.executeBatch(BatcherImpl.java:128)
      3. net.sf.hibernate.impl.SessionImpl.executeAll(SessionImpl.java:2438)
      4. net.sf.hibernate.impl.SessionImpl.execute(SessionImpl.java:2392)
      4 frames