JIRA 6.1.5 DOA - SQL Exception looking for KEY column in customfield table

I just updated to JIRA 6.15, HUGE MISTAKE once again jumping on Atlassian upgrades as they are POORLY TESTED and Q/A is a total failure!  Beyond that, the error in my log file is:

2016-04-21 19:42:23,320 JiraTaskExectionThread-2 WARN neal007 1181x651x1 1m5o77x 100.7.52.33 /secure/admin/IndexReIndex.jspa [c.a.jira.index.AccumulatingResultBuilder] com.atlassian.cache.CacheException: com.atlassian.cache.CacheException: com.atlassian.cache.CacheException: com.atlassian.jira.exception.DataAccessException: org.ofbiz.core.entity.GenericDataSourceException: SQL Exception while executing the following:SELECT KEY, CUSTOMFIELDTYPEKEY, CUSTOMFIELDSEARCHERKEY, cfname, DESCRIPTION, defaultvalue, FIELDTYPE, PROJECT, ISSUETYPE FROM dbo.customfield WHERE ID=? (Incorrect syntax near the keyword 'KEY'.)

I looked in the SQL Database schema for the table "customfield" and there is no column "KEY" defined.  Was one supposed to be added or is this a bad SQL statement in JIRA 6.1.5 that kills it???

I'm dead in the water, again!

6 answers

1 accepted

Haha - gotta love seeing Atlassian uses JIRA 7.1.2.  Hmmmm

Ahh, nicely spotted!  I wonder why I'm not running into it!

This is a perfect example of Atlassian's lack of Q/A in testing new releases. Had anyone actually run an upgrade from 6.1.4 to 6.1.5 using MS-SQL or MySQL it would have failed.  They rely too much on automated testing and distribution which is why I personally, as a software developer and software company owner despise when people rely solely on automated Q/A.  This is the second time in recent past they have broken an upgrade against MS-SQL at least.

I've only done it with MySQL.  I'll need to see why I had it work!  I don't run MS-SQL generally.

0 vote

From what version did you upgrade?  And what documentation did you follow?

6.1.4, standard upgrade process.

I'm still working with support but the first problem is their ALTER statement to add a new column "KEY" to customfields is incorrect. It should be:

INCORRECT:

ALTER TABLE dbo.customfield ADD KEY NVARCHAR(255)

CORRECT:

ALTER TABLE dbo.customfield ADD [KEY] NVARCHAR(255)

0 vote

Sadly, I was intrigued and tried the upgrade.  It worked for me with a plain 6.1.4 and a spot of random data going to 6.1.5.  So I wonder what's different about your install?

Which database are you using?  I'm using MS SQL Server 2014

The SELECT statement should be:

SELECT [KEY], CUSTOMFIELDTYPEKEY, CUSTOMFIELDSEARCHERKEY, cfname, DESCRIPTION, defaultvalue, FIELDTYPE, PROJECT, ISSUETYPE FROM dbo.customfield WHERE ID=?

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published Sunday in Agility

You asked for it, so we delivered: images on issues have arrived

A picture tells a thousand words. And agility boards have just released their latest feature: cover images on issues – so now your board can tell a story at first glance. Upload attachmen...

1,021 views 3 12
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you