Select / Functions
Task 1: Count the number of projects where the project is completed.
mysql> SELECT COUNT(*) FROM projects_kick WHERE completion = 1;
Note the use of
*
.Note the use of a function.
And the condition.
Task 2: Count the number of projects that are created by creator 1 AND the requested budget is larger than 1,000.00.
mysql> SELECT COUNT(*) FROM projects_kick
WHERE creator_id = 1
AND total_amount > 1000;
Note the use of multiple conditions.
Last updated
Was this helpful?