JIRA Operations failing with Column already has a DEFAULT bound to it when GreenHopper is installed

Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.

Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. 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

Summary

Symptoms

  1. Operations (e.g. clone issue) fail and return an error message of the form 'Column already has a DEFAULT bound to it'

The following appears in the atlassian-jira.log:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 [net.java.ao.sql] Exception executing SQL update <ALTER TABLE dbo.AO_60DB71_QUICKFILTER ADD CONSTRAINT df_AO_60DB71_QUICKFILTER_DESCRIPTION DEFAULT NULL FOR DESCRIPTION> java.sql.SQLException: Column already has a DEFAULT bound to it. at net.sourceforge.jtds.jdbc.SQLDiagnostic.addDiagnostic(SQLDiagnostic.java:368) at net.sourceforge.jtds.jdbc.TdsCore.tdsErrorToken(TdsCore.java:2820) at net.sourceforge.jtds.jdbc.TdsCore.nextToken(TdsCore.java:2258) at net.sourceforge.jtds.jdbc.TdsCore.getMoreResults(TdsCore.java:632) at net.sourceforge.jtds.jdbc.JtdsStatement.processResults(JtdsStatement.java:584) at net.sourceforge.jtds.jdbc.JtdsStatement.executeSQL(JtdsStatement.java:546) at net.sourceforge.jtds.jdbc.JtdsStatement.executeImpl(JtdsStatement.java:723) at net.sourceforge.jtds.jdbc.JtdsStatement.executeUpdate(JtdsStatement.java:1166) at net.sourceforge.jtds.jdbc.JtdsStatement.executeUpdate(JtdsStatement.java:1119) at org.apache.commons.dbcp.DelegatingStatement.executeUpdate(DelegatingStatement.java:196) at net.java.ao.DatabaseProvider.executeUpdate(DatabaseProvider.java:2256) at net.java.ao.schema.SchemaGenerator.migrate(SchemaGenerator.java:76) ...

Diagnosis

The problems can occur if:

  • JIRA was upgraded from JIRA 4.4.0 or JIRA 4.4.1 to JIRA 4.4.2 or later.

  • GreenHopper 5.7.2 was installed on JIRA 4.4.0 or JIRA 4.4.1.

  • JIRA is connected to Microsoft SQL Server.

Cause

This problem occurs in JIRA 4.4.2 and later if in the past GreenHopper 5.7.2 was installed when that instance was at JIRA 4.4.0 or JIRA 4.4.1. This is caused by AO-208.

Solution

Resolution

The solution is to shutdown JIRA and remove all constraints from the GreenHopper tables.

  1. Shutdown JIRA.

  2. Open the JIRA database in SQL Server Management Studio.

  3. Open the AO_60DB71_QUICKFILTER table and delete any constraints.

  4. Open the AO_60DB71_SWIMLANE table and delete any constraints.

  5. Restart JIRA.

(Auto-migrated image: description temporarily unavailable)

Updated on April 2, 2025

Still need help?

The Atlassian Community is here for you.