Easy
Given the following 'sales' table:
| sale_id | product_id | sale_date | quantity |
|---------|------------|------------|----------|
| 1 | 1 | 2022-01-01 | 10 |
| 2 | 2 | 2022-01-02 | 5 |
| 3 | 1 | 2022-01-03 | 8 |
Which SQL query calculates the total quantities sold for each product_id?
Author: Vincent CotroStatus: PublishedQuestion passed 2212 times
Edit
6
Community EvaluationsNo one has reviewed this question yet, be the first!
10
Write a SQL query to retrieve the products with a price less than 1000 and sort the results in descending order of price.31
Write a SQL query to retrieve the list of employees with a salary greater than 5100.15
Select only distinct values in a column using SQL12
Which SQL keyword is used to sort the result of a SELECT statement?15
Update a column in an SQL table12
Write a SQL query to insert data into a table10
Write the SQL query to delete a column from a table