SQL How to Use COUNT Correctly with GROUP BY

SQL count(*) in query is little tricky. This post explains why you need to use group by along with count aggregate function