What is the equivalent of sess_count in Drupal 7 As Converting 6.x modules to 7.x explained:


  All session functions starting with sess_*, as well as session_save_session(), are now renamed to drupal_session_* or _drupal_session_*


I have to use sess_count() in my D7 module and naturally I used drupal_session_count() but I ended up having Call to undefined function drupal_session_count() fatal error. I also tried _drupal_session_count() with no luck. User session handling functions page for Drupal 7 didn't mention about this function neither.
Which function should I use in order to count how many users have sessions?
drupal_session_count() was removed from Drupal 7. I'm not sure what an equivalent would be other than writing your own function.

Looks like the user block has it's own query. And admin menu had to replace it too.