Q&A for professionals and students of engineering
select users.id, DATEDIFF(ss, users.creationdate, CURRENT_TIMESTAMP) as AccountAge, count(comments.id) as comment_count, count(posts.id) as post_count from users left join comments on users.id = comments.userid left join posts on users.id = posts.owneruserid group by users.id, users.creationdate order by rand()