To exclude last_name NULL values the query should be
Anonymous Quiz
57%
SELECT id FROM contributors WHERE state = ’VA’ AND last_name IS NULL
43%
SELECT id FROM contributors WHERE state = ’VA’ AND last_name IS NOT NULL
To obtain the top 15 contributors by contribution, let's utilize the … keyword
Anonymous Quiz
89%
LIMIT
10%
WHERE
1%
IF
To make sure that the last character must be a period we use the query …
Anonymous Quiz
66%
SELECT id FROM contributors WHERE first_name LIKE ‘%_.’
13%
SELECT id FROM contributors WHERE first_name LIKE ‘%._’
21%
SELECT id FROM contributors WHERE first_name LIKE ‘_.%’
search will return the lower-case version
Anonymous Quiz
2%
SUBSTR()
2%
TRIM()
3%
UPPER()
93%
LOWER()
Takes the string we hand it in parentheses and returns a part of the string.
Anonymous Quiz
88%
SUBSTR()
12%
TRIM()
Update all row to trim spaces in the ‘state’ field
Anonymous Quiz
85%
UPDATE contributors SET state = TRIM(state)
15%
UPDATE contributors SET state = state.trim()
How many distinct ZIP Codes, for instance, are there in the table?
Anonymous Quiz
19%
SELECT COUNT(zip) FROM contributors
81%
SELECT COUNT(DISTINCT zip) FROM contributors