Installing add-on fails with ORA-01400: cannot insert NULL into AO_6384AB_FEATURE_METADATA_AO

Still need help?

The Atlassian Community is here for you.

Ask the community

Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.

Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Problem

Add-on fails to install via UPM.

The following appears in the atlassian-confluence.log

2016-04-12 13:02:50,389 ERROR [UpmAsynchronousTaskManager:thread-1] [atlassian.event.internal.AsynchronousAbleEventDispatcher] run There was an exception thrown trying to dispatch event [com.atlassian.plugin.event.events.PluginModuleEnabledEvent for com.comalatech.workflow:overview (null)] from the invoker [com.atlassian.confluence.event.ConfluenceListenerHandlersConfiguration$TimingListenerHandler$1$1@3cc9928d]
 -- url: /rest/plugins/1.0/ | referer: http://confluence.example.com/plugins/servlet/upm | userName: jiraadmin
java.lang.RuntimeException: There was a SQL exception thrown by the Active Objects library:
Database:
    - name:Oracle
    - version:Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Advanced Analytics and Real Application Testing options
    - minor version:1
    - major version:12
Driver:
    - name:Oracle JDBC driver
    - version:12.1.0.2.0

java.sql.SQLIntegrityConstraintViolationException: ORA-01400: cannot insert NULL into ("CONFLUENCE"."AO_6384AB_FEATURE_METADATA_AO"."ID")

    at com.atlassian.event.internal.SingleParameterMethodListenerInvoker.invoke(SingleParameterMethodListenerInvoker.java:54)

Diagnosis

Environment

  • Oracle database

Diagnostic Steps

  • Check the sequences of the database user
  • Compare the last number for the 'AO_6384AB_FEATURE_M675681913' sequence with the latest ID of the 'AO_6384AB_FEATURE_METADATA_AO' table

Cause

The sequence is out of sync with the latest ID in the 'AO_6384AB_FEATURE' table.

Workaround

The sequence and table can be dropped and recreated to get back in sync.

Always back up your data before performing any modifications to the database. If possible, test any alter, insert, update, or delete SQL commands on a staging server first.

  1. Stop Confluence
  2. Back up the database.
  3. Drop Sequence AO_6384AB_FEATURE_M675681913 and table 

    DROP SEQUENCE AO_6384AB_FEATURE_M675681913;
    DROP TABLE AO_6384AB_FEATURE_METADATA_AO;
  4. Start Confluence
  5. Install add-on.
Last modified on Apr 22, 2016

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.