MYSQL count of count?
问题 I have a mysql table like: id, visitorid, pageid When a visitor hits the website it stores their visitor id and the page id as a row. I am trying to extract the number of visitors who hit the website exactly X times. (for a chart). so how many visit just one page, how many visit 2 pages... so far I have: SELECT COUNT(visid),visid FROM vislog GROUP BY visid ORDER BY COUNT(visid) DESC But I don't know how to do the next part of counting the counts. Is it possible to do as a mysql query? Edit: I