JIRA Empty Default Issue Type Scheme

Renaud GARNIER October 2, 2017

Hello,

I've lost my Types in default Type Scheme.

If i add a new type, an error occured, have you a solution ?

Thanks

Renaud

My error :

com.querydsl.core.QueryException: Caught SQLException for select OPTION_CONFIGURATION.sequence
from dbo.optionconfiguration OPTION_CONFIGURATION
where OPTION_CONFIGURATION.fieldid = ? and OPTION_CONFIGURATION.fieldconfig = ?
order by OPTION_CONFIGURATION.sequence desc
offset ? rows fetch next ? rows only
com.querydsl.core.QueryException: Caught SQLException for select OPTION_CONFIGURATION.sequence
from dbo.optionconfiguration OPTION_CONFIGURATION
where OPTION_CONFIGURATION.fieldid = ? and OPTION_CONFIGURATION.fieldconfig = ?
order by OPTION_CONFIGURATION.sequence desc
offset ? rows fetch next ? rows only
at com.querydsl.sql.support.JavaSE7SQLExceptionWrapper.wrap(JavaSE7SQLExceptionWrapper.java:41) [querydsl-sql-4.0.7.jar:?]
4.0.7.jar:?]

...

2 answers

1 accepted

0 votes
Answer accepted
Andy Heinzer
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 3, 2017

Hi Renaud,

Your error looks very similar to this other MS SQL select error in Exception Errors in JIRA 7.3.7 after upgrade with Create Issue.  In which case, if your SQL database is still using MS SQL 2008, that version of SQL does not support the 'offset' SQL statement.

Support for SQL 2008 does not include Jira 7.2.x versions and higher.   If you were using a Jira 7.1 or before, it wouldn't be trying to use that SQL syntax.  Switching databases documentation has steps you can follow to move your database to a supported platform.

If that isn't the problem, and you're using a SQL 2012 or 2014 database instance, then I'd like to know more about what happened in your instance to cause this error.

Renaud GARNIER October 4, 2017

Thank you for your suggestions.
Andrew won the point, my problem was SQL2008. I put my db on SQL2012 and the pb disappeared.

For Branden, the first statement sql returns me a record (4).

0 votes
somethingblue
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 3, 2017

Hi Renaud,

  • How did the issue types get lost?

There is an article title JIRA throws NumberFormatException when adding new issue types that may help:

Run the following SQL command to see if it returns back empty:

select id from propertyentry where property_key = 'jira.avatar.issuetype.default.id'

Cause

The error is caused by an empty jira.avatar.issuetype.default.id in the database

Workaround

  • Please stop the JIRA Server
  • Run the following SQL queries
insert into propertyentry
  (id, entity_name, entity_id, property_key, propertytype)
select
  4, 'jira.properties', 1, 'jira.avatar.issuetype.default.id', 5
where not exists
  (select id from propertyentry where property_key = 'jira.avatar.issuetype.default.id');
insert into propertystring
  (id, propertyvalue)
select
  (select id from propertyentry where property_key = 'jira.avatar.issuetype.default.id' limit 1), '10300'
where not exists
  (select id from propertyentry pe inner join propertystring ps using (id)
  where pe.property_key = 'jira.avatar.issuetype.default.id');
insert into propertyentry
  (id, entity_name, entity_id, property_key, propertytype)
select
  2, 'jira.properties', 1, 'jira.avatar.issuetype.subtask.default.id', 5
where not exists
(select id from propertyentry where property_key = 'jira.avatar.issuetype.subtask.default.id');
insert into propertystring
  (id, propertyvalue)
select
  (select id from propertyentry where property_key = 'jira.avatar.issuetype.subtask.default.id' limit 1), '10316'
where not exists
(select id from propertyentry pe inner join propertystring ps using (id)
    where pe.property_key = 'jira.avatar.issuetype.subtask.default.id');
  • Restart your JIRA Server

Let me know if that works for you.

Cheers,

Branden

Suggest an answer

Log in or Sign up to answer