Loading exercise…
Loading exercise…
Exercises are built for a keyboard. Read the task here, then open this page on a laptop to solve it.
regexp_replace. regexp_replace(text, pattern, replacement, 'g') replaces every match of a pattern. The pattern [^0-9] means 'any character that is not a digit', so replacing it with '' keeps only the digits. RIGHT(text, n) keeps the last n characters, and LENGTH tells you how long the result is.
select product_name, regexp_replace(product_name, '[^A-Za-z ]', '', 'g') as letters_only from products
The CRM import has phone numbers in five formats, such as 555.643.0064, (555) 788-6885 and +1 555 244 8804. Data ops wants the numbers that belong to more than one contact, which usually means a duplicate person.
Return phone and contacts for every phone number shared by more than one contact, where phone is the number reduced to its last 10 digits (no spaces, dots, dashes, brackets or +1 prefix).
Loading the Brightline dataset…
Language
Full plan
SQL ✓ · Excel and Power BI also included
Cancel anytime · 14-day full refund · Secure payment by Stripe