SQL Exercises: Count all orders of a specific date
SQL Aggregate Functions: Exercise-18 with Solution
Write a SQL statement that counts all orders for a date August 17th, 2012.
Sample table: orders
SELECT COUNT(*) FROM orders WHERE ord_date='2012-08-17';
Output of the Query:
Have another way to solve this solution? Contribute your code (and comments) through Disqus.
Previous: Write a SQL statement to find the highest purchase amount with their ID, for only those salesmen whose ID is within the range 5003 and 5008.
Next: Write a SQL statement that count the number of salesmen for whom a city is specified. Note that there may be spaces or no spaces in the city column if no city is specified.
What is the difficulty level of this exercise?