Complete the code to select all columns from the table named 'employees'.
SELECT [1] FROM employees;The asterisk (*) means to select all columns from the table.
Complete the code to filter rows where the 'age' column is greater than 30.
SELECT * FROM users WHERE age [1] 30;
The '>' operator filters rows where age is greater than 30.
Fix the error in the SQL query to count the number of rows in the 'orders' table.
SELECT COUNT([1]) FROM orders;Using COUNT(*) counts all rows in the table.
Fill both blanks to select the 'name' and 'salary' columns from 'employees' where salary is at least 50000.
SELECT [1], [2] FROM employees WHERE salary >= 50000;
We select 'name' and 'salary' columns to see employees earning at least 50000.
Fill all three blanks to create a query that selects 'product', counts 'sales', and filters where sales are more than 100.
SELECT [1], COUNT([2]) FROM sales_data GROUP BY [3] HAVING COUNT([2]) > 100;
The query groups sales by product, counts sales by sale_id, and filters groups with more than 100 sales.