How To Export Users Inactive For More Than 90 Days From Orchestrator ?

How to export from Orchestrator, the users inactive for more than 90 days?

Issue Description: The option to export a list of users that were inactive for more than 90 days, is not found.

Resolution: The below query can be run in the Orchestrator database,

 SELECT * FROM AuditLogs A 

 JOIN (SELECT * FROM UserAccounts where DATEDIFF(DD,ISNULL(LastLoginTime,0), GETDATE()) >90) M

 ON A.UserId=M.UserId

This query returns a list of users who have not logged in to Orchestrator for 90 days. The value can be changed in the query as needed.

What about Automation Cloud deployments? how could it be done?

For automation cloud you can go with the API call to find the last active column as per the below screenshot.
How to get token for this endpoint “**0124813c-d915-4f93-ba7c-1ced3c5c1be1**”