Professional Documents
Culture Documents
Advanced: Novice
Advanced: Novice
Back to Results
Question 11
Advanced
Intermediate
Novice
1 2 3 4 5 6 7 8 9 10 11 12 13
https://assessment-v2.datacamp.com/15e09043-62d9-4b3e-a10c-638c40a5ea4c/review?returnUrl=https%253A%252F%252Fapp.datacamp.com%252Fcertificat… 1/2
23:43 21/04/2024 Skill Assessment
In your code, you are counting the number of rows where the vendor_state is not NULL. However, in the correct code, the
condition should be vendor_state IS NULL to count the number of rows where the vendor_state is NULL. This is why your
output is not what you expected.
Yes No
For the vendors table, return the number of the rows with missing values in the vendor_state column.
-- vendors
| vendor_name | vendor_city | vendor_state |
|---------------------|----------------|-----------------|
| CHONZIE INC | ASHEVILLE | NC |
| ... | ... | ... |
| WEBSEDGE LIMITED | LONDON | |
| ... | ... | ... |
SELECT
COUNT(*)
FROM vendors
WHERE vendor_state IS NOT NULL ;
WHERE vendor_state IS NULL ;
count count
2 286
Incorrect answer
Difficulty MEDIUM
Report Issue
https://assessment-v2.datacamp.com/15e09043-62d9-4b3e-a10c-638c40a5ea4c/review?returnUrl=https%253A%252F%252Fapp.datacamp.com%252Fcertificat… 2/2