Can any one help me on the Groovy script
following details needed
-user name
-mailid
-lastlogin time
-groups (ex: Jira users,Admins...)
I have this when using Crowd
SELECT d.directory_name AS "Directory",
u.user_name AS "Username",
FROM_UNIXTIME((CAST(attribute_value AS UNSIGNED)/1000)) AS "Last Login"FROM cwd_user u
JOIN cwd_directory d ON u.directory_id = d.id
LEFT JOIN cwd_user_attributes ca ON u.id = ca.user_id AND ca.attribute_name = 'login.lastLoginMillis'WHERE u.active = 1AND d.active = 1AND u.lower_user_name IN (SELECT DISTINCT lower_child_name
FROM cwd_membership m
JOIN licenserolesgroup gp ON m.parent_name = gp.GROUP_ID)AND (u.id IN (SELECT ca.user_id
FROM cwd_user_attributes caWHERE attribute_name = 'login.lastLoginMillis' AND FROM_UNIXTIME(ROUND(ca.attribute_value/1000)) <= (current_date - interval 60 day))OR u.id NOT IN (SELECT ca.user_id
FROM cwd_user_attributes caWHERE attribute_name = 'login.lastLoginMillis'))ORDER BY "Last Login" DESC;
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.