[Building Sakai] Overall usage statistics and SAKAI_EVENT
Stephen Marquard
stephen.marquard at uct.ac.za
Sat Sep 12 05:40:50 PDT 2009
The user id isn't in a login event or any other event because it's in the session info.
A more concise query to get the number of users in a day would be:
SELECT COUNT(DISTINCT SESSION_USER) from SAKAI_SESSION
where SESSION_START > to_date('2009-09-09 0:00:00', 'YYYY-MM-DD
HH24:MI:SS') and
SESSION_START < to_date('2009-09-10 0:00:00', 'YYYY-MM-DD HH24:MI:SS');
Regards
Stephen
>>> Joshua Swink <joshua.swink at gmail.com> 9/12/2009 1:08 AM >>>
I'm trying to get overall usage statistics for our Sakai site.
First question: Why isn't the user id stored for a user.login event?
Was this considered a privacy issue? It would make this task a lot
easier.
Here is the query I'm using to get the number of people who used Sakai
in a single day. It relies on the assumption that any person who is
'present' at a '/presence/~%' location must be a user visiting its own
workspace. This is not a perfect assumption but it seems to be the
best I can do for now.
select distinct A.ref
from sakai_event A, sakai_event B
where
A.event='pres.begin' and
A.ref like '/presence/~%' and
A.session_id = B.session_id and
B.event = 'user.login' and
B.event_date > to_date('2009-09-09 0:00:00', 'YYYY-MM-DD
HH24:MI:SS') and
B.event_date < to_date('2009-09-10 0:00:00', 'YYYY-MM-DD HH24:MI:SS');
Josh
_______________________________________________
sakai-dev mailing list
sakai-dev at collab.sakaiproject.org
http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
TO UNSUBSCRIBE: send email to sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of "unsubscribe"
More information about the sakai-dev
mailing list