Find users by created date rather than last authenticated date

Still need help?

The Atlassian Community is here for you.

Ask the community

Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.

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

When looking for users (possibly in the case to remove some to free up licenses), the /admin/users endpoint only provides a last authenticated date and doesn't mention when the user was originally created.

Environment

Bitbucket Server

Solution

The following DB query can be run against your database to get users based on the created date. Note: This does not state if those users consume a license or any other information. 


For PSQL 

SELECT * FROM cwd_user WHERE CAST(created_date AS Date) >= 'YYYY-MM-DD'


For Oracle 

 SELECT * FROM cwd_user WHERE CAST(created_date AS Date) >= 'DD-MM-YYYY';



Last modified on Jun 28, 2022

Was this helpful?

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