Group By in SQL:
The SQL GROUP BY statement is used together with the SQL aggregate functions to group the retrieved data by one or more columns.
Example :
Sales(OrderId,Customer,Price, Date)
1.Select Customer,sum(price) from Sales group by Customer
No comments:
Post a Comment