You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
5 lines
246 B
MySQL
5 lines
246 B
MySQL
5 years ago
|
/*Write a SQL statement to find the highest purchase amount on a date '2012-08-17' for each salesman with their ID.*/
|
||
|
SELECT salesman_id,MAX(purch_amt)
|
||
|
FROM orders
|
||
|
WHERE ord_date = '2012-08-17'
|
||
|
GROUP BY salesman_id;
|