The User Statistics in the User Management page are displayed as "Not Recorded"
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
The content on this page relates to database updates which are not supported by our Atlassian Support Offerings. Consequently, Atlassian can not guarantee providing any support for it. Please be aware that this material is provided for your information only and using it is done so at your own risk.
Jira admins may sometimes notice that one or all of their user(s) statistics, such as login count, login date, previous login, last login failed, current failed logins, and total failed logins, are all displayed as "Not Recorded" after migrating users between user directories.
Diagnosis
When users are migrated between user directories using third party plugins (not via the built in "migrate users from one directory to another" functionality) then one or all of the user's statistics, such as login count, login date, previous login, last login failed, current failed logins, and total failed logins, are all displayed as "Not Recorded" after migrating users between user directories.

Cause
This problem may occur due to incorrect mapping of the Directory_id in the cwd_user_attributest able. The table sometimes contains the user's old directory ID even though they have migrated to a new user directory.
Solution
Find the user id and directory_id of the affected user to find the directory to which they belong.
1
SELECT id,directory_id FROM cwd_user where user_name = 'affected user name here';
Now use the User ID returned from the previous SQL query to find the directory_id which is stored in thecwd_user_attributes table.
1
SELECT directory_id FROM cwd_user_attributes where user_id =<id from the previous query>;
Compare the directory_id returned from both the tables.
In case the directory_id returned from the cwd_user_attributes table still refers to the old directory of the user, then backup the database, stop Jira and then update the directory for this id to the new directory id.
1
UPDATE cwd_user_attributes SET directory_id =<new_directory_id> WHERE user_id=<id from the initial query>;
Start Jira
Solution provided involves running SQL scripts directly on your database, we strongly recommend you do this first on a non-production, staging or test environment before running the scripts on your production database. We also strongly recommend you take a backup of your data before making any modifications via SQL scripts.
Was this helpful?