You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
How to get the list of users in confluence who has no access /linked to any of the spaces
Currently confluence user group has access to many of the spaces. Through which all licensed users are accessing the space.
I want to get the list of users who have no access to any space or created any space (excluding the access they have due to confluence user group assignment)
Please let me know how to fetch this?
if all access to the spaces is implemented via group assignments and no individual permissions are assigned, this is how it works:
1. list all groups that are permitted in spaces with the following database query:
FROM SPACEPERMISSIONS sp
JOIN SPACES s ON sp.spaceid = s.spaceid
LEFT JOIN user_mapping um ON sp.permusername = um.user_key
WHERE s.spacekey in (select spacekey from spaces s where s.SPACETYPE like 'global')
group by sp.permgroupname
order by sp.permgroupname
2. these groups are listed in another query that shows which users belong to the confluence-users group but not to any of the listed groups you fetched before:
with data as
(select u.lower_user_name, u.first_name, u.last_name, g.group_name, u.email_address
from cwd_user u
join cwd_membership m
on u.id = m.child_user_id
join cwd_group g
on g.id = m.parent_id
order by u.lower_user_name)
select lower_user_name, first_name, last_name, group_name, email_address
from data t
where group_name = 'confluence-users'
and not exists (select *
from data g
where t.lower_user_name = g.lower_user_name
and g.group_name in ('confluence-administrators',
Hope that helps!