How to extract a list of users with (view) access to a confluence space

I would like to have a list of users with access to a space.

Nicer would be an 'add-on'/macro in the space itself so that the information is always up to date.

1 answer

Hi Gerard,

 

You can list which spaces an specific user can access by running the following SQL query against the Confluence database:

 information Replace <user_name> with the actual username of the user, in lowercase.

SELECT s.SPACEKEY
FROM SPACEPERMISSIONS sp 
JOIN SPACES s ON s.SPACEID = sp.SPACEID
JOIN user_mapping um ON um.user_key = sp.PERMUSERNAME
WHERE um.lower_username = '&lt;user_name&gt;'
GROUP BY s.SPACEKEY
ORDER BY s.SPACEKEY;

 

You can see full information in the link below:

https://confluence.atlassian.com/display/CONFKB/How+to+list+which+spaces+a+user+can+access

 

Cheers,

Enunes

Thanks. This gives me for each known user which space the user can access. I need the opposite

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Kesha Thillainayagam
Posted Apr 13, 2018 in Confluence

We want to hear how your non-technical teams are using Confluence!

Hi Community! Kesha (kay-sha) from the Confluence marketing team here! Can you share stories with us on how your non-technical (think Marketing, Sales, HR, legal, etc.) teams are using Confluen...

372 views 20 10
Join discussion

Atlassian User Groups

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

Find a group

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

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you