Uploaded image for project: 'Jira Data Center'
  1. Jira Data Center
  2. JRASERVER-31545

User count toward license is not correct in JIRA

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Low
    • None
    • 5.2.5
    • None

    Description

      When JIRA is using more than one User Directory, the user count can get incorrect after User Directories are removed and added a few number of times.

      I'm not sure how JIRA is counting users toward the license today, but I believe the following query should return the most correct user count.

      SELECT distinct u.lower_user_name
      FROM cwd_user u
      JOIN cwd_membership m
      ON u.id = m.child_id
      AND u.directory_id = m.directory_id
      JOIN schemepermissions sp
      ON LOWER(m.parent_name) = LOWER(sp.perm_parameter)
      JOIN cwd_directory d
      ON m.directory_id = d.id
      WHERE sp.permission IN ('0','1','44') AND d.active = '1' and u.active = '1';
      

      The query may need some changing considering nested groups.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              malmeida Marcus Silveira
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: