Several actions such as issue ranking, move, export are failing

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

The following appears in the atlassian-greenhopper.log:

1 Details: ------- org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getHtml' in class com.atlassian.jira.issue.fields.layout.column.ExcelColumnLayoutItem threw exception com.atlassian.greenhopper.manager.lexorank.LexoRankIntegrityException: Expected exactly 2 rows; the maximum marker row and the lowest ranked row for rank field[id=10700] at templates/jira/issue/table/macros.vm[line 115, column 34] at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:337) at

Diagnosis

Looking into the database, the AO_60DB71_LEXORANK is empty (has no rows in it)

Run the following Query in the DB (NOTE: the query is using the FIELD_ID = 10700 from the error above, modify the id to match the error you receive):

1 2 3 4 SELECT "FIELD_ID", "ID", "ISSUE_ID", "LOCK_HASH", "LOCK_TIME", "RANK", "TYPE" FROM "AO_60DB71_LEXORANK" WHERE "FIELD_ID" = 10700 AND "TYPE" IN (0, 2);

With the above Query you should see Exactly 2 rows as displayed here:

1 2 3 4 5 FIELD_ID | ID | ISSUE_ID | LOCK_HASH | LOCK_TIME | RANK | TYPE ----------+----+----------------------+-----------+-----------+-----------+------ 10700 | 7 | -9223372036854775808 | | | 0|000000: | 0 10700 | 8 | 9223372036854775807 | | | 0|zzzzzz: | 2 (2 rows)

If the query is empty the endmarkers are missing and need to be added as described in the Resolution below.

Cause

It seems that the ranking has not been migrated to the Lexorank format.

This could be because the JIRA Agile plugin was downgraded in the past and the ranking never got migrated after that.

Solution

Resolution

  • Get the rank field id from the above error message. In this case, it is 10700.

  • Stop JIRA

  • Run the following statements in the database replacing the <Rank FIELD_ID> with the rank field id in your case. The "Rank FIELD_ID" can be obtained from "FIELD_ID" shown in query result of the SQL query shown in diagnosis step.

    1 2 INSERT INTO "AO_60DB71_LEXORANK" ("FIELD_ID", "ISSUE_ID", "LOCK_HASH", "LOCK_TIME", "RANK", "TYPE") VALUES (<Rank FIELD_ID>, -9223372036854775808, null, null, '0|000000:', 0); INSERT INTO "AO_60DB71_LEXORANK" ("FIELD_ID", "ISSUE_ID", "LOCK_HASH", "LOCK_TIME", "RANK", "TYPE") VALUES (<Rank FIELD_ID>, 9223372036854775807, null, null, '0|zzzzzz:', 2);
  • Start JIRA

  • Reindex JIRA

Updated on April 2, 2025

Still need help?

The Atlassian Community is here for you.