patchgeneric.sql Fails to Help Upgrading Fisheye from Version 1.6.6 to Version 2.8.0

Still need help?

The Atlassian Community is here for you.

Ask the community

Symptoms

Execution of patchgeneric.sql fails as follow:

java -Xmx2048m -jar <FISHEYE_HOME>/lib/hsqldb-1.8.0.10.jar --inlineRC "URL=jdbc:hsqldb:file:<FISHEYE_INST>/var/data/crudb/crucible;shutdown=true,USER=sa,PASSWORD=" patchgeneric.sql
SQL Error at 'patchgeneric.sql' line 3:
"delete from FR_EXTRA where fileRevision not in (Select REVISION_ID from REVISION)"
Integrity constraint violation FKD00FBDDBD91F70A1 table: REVISION_COMMENT

 

Cause

Integrity constraint violation FKD00FBDDBD91F70A1 table: REVISION_COMMENT

This is happening because there is file revisions in the Fisheye/Crucible database for file versions that have not been indexed by Fisheye. This could happen with Crucible 1.6.6 but in the later versions it became mandatory for a crucible revision to have its associated file version indexed by Fisheye.

Resolution

Execute the attached patch-Revision_Comment.sql:

java -Xmx2048m -jar <FISHEYE_HOME>/lib/hsqldb-1.8.0.10.jar --inlineRC "URL=jdbc:hsqldb:file:<FISHEYE_INST>/var/data/crudb/crucible;shutdown=true,USER=sa,PASSWORD=" patch-Revision_Comment.sql

Then execute again the original command using patchgeneric.sql

java -Xmx2048m -jar <FISHEYE_HOME>/lib/hsqldb-1.8.0.10.jar --inlineRC "URL=jdbc:hsqldb:file:<FISHEYE_INST>/var/data/crudb/crucible;shutdown=true,USER=sa,PASSWORD=" patchgeneric.sql

Unable to upgrade from version 1.6.6 to version 2.8.0

Last modified on Jul 31, 2018

Was this helpful?

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