Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,301,527
Community Members
 
Community Events
165
Community Groups

Deleting inactive users crowd

I would like to delete the five users who have been inactive the longest i Crowd. Is there any way to see wich users that have been inactive the longest?

1 answer

0 votes

Hi @Vegard Haneberg 

if you have access to the database behind Crowd, you can do a left join between cwd_user and cwd_user_attribute 

 

something like this should work (tweaked on my phone from a more complicated query, so may need to be tweaked, and for psql so if you’re running my/ms/oracle may need to be adjusted).

SELECT

  u.lower_user_name AS username,

 FROM_UNIXTIME(ua.attribute_lower_value/1000) AS lastLogin

FROM

  cwd_user AS u

    LEFT JOIN cwd_user_attribute AS ua ON ua.user_id = u.id AND attribute_name = 'lastAuthenticated'

ORDER BY

  ua.attribute_lower_value, u.lower_user_name;

 

CCM

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Apps & Integrations

📅 Partner Webinar & Events Opportunities: July 2022

Hi community 👋, Here is another monthly roundup of the partner-organized events in July 2022. If there is any event missing please let me know in the comments below 🙏 If you're looking for Atla...

29 views 0 2
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you