have a comments table and need to get the first comment date (first inserted record) of each users in the table.
Output will be :
user_id first_comment_date
You can use min()
try
SELECT user_id, MIN(comment_date)
FROM commentstable
GROUP BY user_id;