I am counting the rows in a mysql table called ptb_profile_views.
ptb_profile_views
My table looks like this:
id | profile_id | viewed_profile_id | date
Try the following (assuming viewed_profile_id is 6):
SELECT COUNT(DISTINCT profile_id) FROM ptb_profile_views WHERE viewed_profile_id=6