error has occurred after upgrading Jira version from 7.2.5 to 7.5.0

Hello Jira Masters ,

i found this error after upgrading Jira version from 7.2.5 to 7.5.0 :

 

2017-09-27 10:20:35,155 Caesium-1-4 ERROR      [c.a.upgrade.core.DefaultUpgradeTaskFactoryProcessor] Upgrade task [host,buildNumber=73011] failed

com.querydsl.core.QueryException: Caught SQLSyntaxErrorException for insert into OS_CURRENTSTEP (ID, ENTRY_ID, STEP_ID, ACTION_ID, OWNER, START_DATE, DUE_DATE, FINISH_DATE, STATUS, CALLER)

select hs.ID, hs.ENTRY_ID, hs.STEP_ID, hs.ACTION_ID, hs.OWNER, hs.START_DATE, hs.DUE_DATE, null, hs.STATUS, hs.CALLER

from OS_HISTORYSTEP hs

where hs.ENTRY_ID in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) and exists (select ISSUE.id

from jiraissue ISSUE

where ISSUE.workflow_id = hs.ENTRY_ID and not exists (select OS_CURRENTSTEP.ID

from OS_CURRENTSTEP OS_CURRENTSTEP

where OS_CURRENTSTEP.ENTRY_ID = ISSUE.workflow_id)) and hs.ID = (select * from (

  select hs2.ID

from OS_HISTORYSTEP hs2

where hs.ENTRY_ID = hs2.ENTRY_ID and hs2.FINISH_DATE is not null and not exists (select prevStep.ID

from OS_HISTORYSTEP_PREV prevStep

where prevStep.PREVIOUS_ID = hs2.ID)

order by hs2.FINISH_DATE desc

) where rownum <= ?) and (select * from (

  select count(hs2.FINISH_DATE)

from OS_HISTORYSTEP hs2

where hs.ENTRY_ID = hs2.ENTRY_ID and hs2.FINISH_DATE is not null and not exists (select prevStep.ID

from OS_HISTORYSTEP_PREV prevStep

where prevStep.PREVIOUS_ID = hs2.ID)

group by hs2.FINISH_DATE

order by hs2.FINISH_DATE desc

) where rownum <= ?) = ?

        at com.querydsl.sql.DefaultSQLExceptionTranslator.translate(DefaultSQLExceptionTranslator.java:50)

        at com.querydsl.sql.Configuration.translate(Configuration.java:459)

        at com.querydsl.sql.dml.SQLInsertClause.execute(SQLInsertClause.java:445)

        at com.atlassian.jira.upgrade.tasks.UpgradeTask_Build73011.lambda$restoreEntriesFromHistory$3(UpgradeTask_Build73011.java:231)

        at com.atlassian.jira.upgrade.tasks.UpgradeTask_Build73011$$Lambda$994/353337797.runQuery(Unknown Source)

        at com.atlassian.jira.database.DefaultQueryDslAccessor.lambda$executeQuery$0(DefaultQueryDslAccessor.java:68)

        at com.atlassian.jira.database.DefaultQueryDslAccessor$$Lambda$517/291225287.apply(Unknown Source)

        at com.atlassian.jira.database.DatabaseAccessorImpl.lambda$runInTransaction$0(DatabaseAccessorImpl.java:99)

        at com.atlassian.jira.database.DatabaseAccessorImpl$$Lambda$518/767133039.run(Unknown Source)

        at com.atlassian.jira.database.DatabaseAccessorImpl.executeQuery(DatabaseAccessorImpl.java:68)

        at com.atlassian.jira.database.DatabaseAccessorImpl.runInTransaction(DatabaseAccessorImpl.java:94)

        at com.atlassian.jira.database.DefaultQueryDslAccessor.executeQuery(DefaultQueryDslAccessor.java:67)

        at com.atlassian.jira.upgrade.tasks.UpgradeTask_Build73011.restoreEntriesFromHistory(UpgradeTask_Build73011.java:197)

        at com.atlassian.jira.upgrade.tasks.UpgradeTask_Build73011.runUpgrade(UpgradeTask_Build73011.java:98)

        at com.atlassian.upgrade.core.DefaultUpgradeTaskFactoryProcessor.runOneUpgradeTask(DefaultUpgradeTaskFactoryProcessor.java:109)

        at com.atlassian.upgrade.core.DefaultUpgradeTaskFactoryProcessor.lambda$performUpgradesUnsafe$13(DefaultUpgradeTaskFactoryProcessor.java:80)

        at com.atlassian.upgrade.core.DefaultUpgradeTaskFactoryProcessor$$Lambda$956/1155445222.test(Unknown Source)

        at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:174)

        at java.util.stream.SortedOps$RefSortingSink.end(SortedOps.java:395)

        at java.util.stream.Sink$ChainedReference.end(Sink.java:258)

        at java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:530)

        at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:516)

        at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:502)

        at java.util.stream.FindOps$FindOp.evaluateSequential(FindOps.java:152)

        at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)

        at java.util.stream.ReferencePipeline.findFirst(ReferencePipeline.java:464)

        at com.atlassian.upgrade.core.DefaultUpgradeTaskFactoryProcessor.performUpgradesUnsafe(DefaultUpgradeTaskFactoryProcessor.java:81)

        at com.atlassian.upgrade.core.DefaultUpgradeTaskFactoryProcessor.performUpgrades(DefaultUpgradeTaskFactoryProcessor.java:46)

        at com.atlassian.upgrade.core.DefaultUpgradeTaskManager.upgradeHostApp(DefaultUpgradeTaskManager.java:41)

        at com.atlassian.jira.upgrade.LicenseCheckingUpgradeService.executeUpgrades(LicenseCheckingUpgradeService.java:134)

        at com.atlassian.jira.upgrade.LicenseCheckingUpgradeService.runUpgrades(LicenseCheckingUpgradeService.java:97)

        at com.atlassian.jira.upgrade.ClusterLockingUpgradeService.runUpgrades(ClusterLockingUpgradeService.java:35)

        at com.atlassian.jira.upgrade.LoggingUpgradeService.lambda$runUpgradesWithLogging$0(LoggingUpgradeService.java:28)

        at com.atlassian.jira.upgrade.LoggingUpgradeService$$Lambda$939/678203302.get(Unknown Source)

        at com.atlassian.jira.upgrade.LoggingUpgradeService.runWithTaskLogging(LoggingUpgradeService.java:43)

        at com.atlassian.jira.upgrade.LoggingUpgradeService.runUpgradesWithLogging(LoggingUpgradeService.java:28)

        at com.atlassian.jira.upgrade.IndexingUpgradeService.runUpgrades(IndexingUpgradeService.java:19)

        at com.atlassian.jira.upgrade.UpgradeScheduler.runHostUpgrades(UpgradeScheduler.java:95)

        at com.atlassian.jira.upgrade.UpgradeScheduler.runUpgrades(UpgradeScheduler.java:76)

        at com.atlassian.jira.upgrade.UpgradeScheduler$$Lambda$291/1923432757.runJob(Unknown Source)

        at com.atlassian.scheduler.core.JobLauncher.runJob(JobLauncher.java:153)

        at com.atlassian.scheduler.core.JobLauncher.launchAndBuildResponse(JobLauncher.java:118)

        at com.atlassian.scheduler.core.JobLauncher.launch(JobLauncher.java:97)

        at com.atlassian.scheduler.caesium.impl.CaesiumSchedulerService.launchJob(CaesiumSchedulerService.java:443)

        at com.atlassian.scheduler.caesium.impl.CaesiumSchedulerService.executeClusteredJob(CaesiumSchedulerService.java:438)

        at com.atlassian.scheduler.caesium.impl.CaesiumSchedulerService.executeClusteredJobWithRecoveryGuard(CaesiumSchedulerService.java:462)

        at com.atlassian.scheduler.caesium.impl.CaesiumSchedulerService.executeQueuedJob(CaesiumSchedulerService.java:390)

        at com.atlassian.scheduler.caesium.impl.CaesiumSchedulerService$1.consume(CaesiumSchedulerService.java:285)

        at com.atlassian.scheduler.caesium.impl.CaesiumSchedulerService$1.consume(CaesiumSchedulerService.java:282)

        at com.atlassian.scheduler.caesium.impl.SchedulerQueueWorker.executeJob(SchedulerQueueWorker.java:65)

        at com.atlassian.scheduler.caesium.impl.SchedulerQueueWorker.executeNextJob(SchedulerQueueWorker.java:59)

        at com.atlassian.scheduler.caesium.impl.SchedulerQueueWorker.run(SchedulerQueueWorker.java:34)

        at java.lang.Thread.run(Thread.java:745)

Caused by: java.sql.SQLSyntaxErrorException: ORA-00904: "HS"."ENTRY_ID": invalid identifier

 

        at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:450)

        at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:399)

        at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:1059)

        at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:522)

        at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:587)

        at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:225)

        at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:53)

        at oracle.jdbc.driver.T4CPreparedStatement.executeForRows(T4CPreparedStatement.java:943)

        at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1150)

        at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:4798)

        at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:4875)

        at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeUpdate(OraclePreparedStatementWrapper.java:1361)

        at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:98)

        at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:98)

        at com.querydsl.sql.dml.SQLInsertClause.execute(SQLInsertClause.java:423)

        ... 50 more

 

 

Can you help please ? 

thank you

2 answers

1 accepted

0 votes

I have seen this specific error happen on Jira instances that are still running an Oracle 11g or earlier database.  Jira 7.x.x versions do have support for Oracle databases, but only 12c versions.   This is documented in the Supported Platforms docs.

I created a new KB to help users address this problem, please see Upgrade task buildNumber=73011 failed com.querydsl.core.QueryException: Caught SQLSyntaxErrorException - JIRA Knowledge Base - Atlassian Documentation

0 votes

Hi, did you review the upgrade notes for 7.3 and 7.4.   Take a look at the 7.3 notes.  There's some changes there to mysql and ssl changes.

You may also try stepping up.  Upgrading to 7.3 and 7.4 to see where you fail.

Also, can you indicate what upgrade process you're following, database and os you're running?  That may help the community resolve.

Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

2,932 views 12 18
Join discussion

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
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot