SQL needed for space access by user

I need to produce a report, for some arbitrary period of time and every space, who has accessed the space and how many times during the time period. Does anyone have any idea how I might do this? I'm relatively inexperienced with SQL and even less so with the Confluence schema.


We're running Confluence version 5.7.1 and MySQL 5.1.73.




1 answer

0 votes

Confluence doesn't natively track "access" to spaces, so there's nothing stored you could even begin to query.

You'll need to look at one of the tracker add-ons you can get.

Instead of user access to a space, would it be possible to get the number of page views per user for a space via a SQL query?

Ann Worley Atlassian Team Jun 12, 2017

Confluence doesn't write records to the database to track users accessing pages. There are user access logs you can turn on, but they won't look like a report.

Nic's suggestion of trying a tracking add-on is a good idea.

There are other ideas on this page:

How to Enable User Access Logging

Please, re-read the first sentence of my answer.

Sorry, when you wrote spaces, I didn't understand that to mean pages as well. Thanks for the assistance.

Thanks, Ann. I'll take a look at the page.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Feb 06, 2019 in Confluence

Try out the new editing experience

Hi team, I’m Avinoam, a product manager on Confluence Cloud, and today I’m really excited to let the Community know that all customers can now try out the new editing experience and see some of the ...

971 views 50 8
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