I have a table with columns user_id, time_stamp and activity which I use for recoding user actions for an audit trail.
How can I COUNT the number of unique user_id where time_stamp=0 when there might be multiple such rows, differing only in in the activity text?
Sounds like you need to use: