- Having clause is used after group by clause whereas where clause is used before group by clause
- Having clause is used to filter the groups and where clause is used to filter rows
Syntax
select customer_id,Count(*) as visits
from Customer_Info
where age>25
group by customer_id
having Count(*)>10
Leave a comment