Identifying the difference between restricted and unrestricted comments in the Jira Database

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

In the Jira Database, restricted comments have the 'rolelevel' set to the ID of the role, or 'actionlevel' set to the group they are restricted to.

Below we will demonstrate how to identify these issues.

Solution

Finding restricted Comments

We spun up a test instance and created three comments:

  • One comment that is unrestricted

  • One comment that is restricted to Administrators role

  • One comment restricted to members of group 'group1'

Next, we did a simple query to find out the difference between the three comments:

select * from jiraaction;

Results:

id

issueid

author

actiontype

actionlevel

rolelevel

actionbody

created

updateauthor

updated

actionnum

10000

10000

JIRAUSER10000

comment

(null)

(null)

This comment is available to everyone

2021-01-08 11:57:06

JIRAUSER10000

2021-01-08 11:57:06

(null)

10001

10000

JIRAUSER10000

comment

(null)

10002

This comment is restricted to the Administrators role

2021-01-08 11:57:26

JIRAUSER10000

2021-01-08 11:57:26

(null)

10002

10000

JIRAUSER10000

comment

group1

(null)

This comment is restricted to members of group1

2021-01-08 11:58:31

JIRAUSER10000

2021-01-08 11:58:31

(null)

From the results, it appears that:

  • Unrestricted comments have 'rolelevel' and 'actionlevel' set to (null)

  • Role-restricted comments have the 'role level' set to the ID of the Role (in this case, Administrators)

  • Group-restricted comments have the 'actionlevel' set to the name of the Group

To find all comments restricted to a specific role

Find the role ID and use it to replace <ROLE_ID> in the following query:

SELECT * FROM jiraaction WHERE rolelevel = '<ROLE_ID>';

To find all comments restricted to a specific group

Replace <GROUP_NAME> in the following query with the group name:

SELECT * FROM jiraaction WHERE actionlevel = '<GROUP_NAME>';

Updated on May 22, 2025

Still need help?

The Atlassian Community is here for you.