Company: Nasdaq_18oct
Difficulty: medium
Problem Description Write a SQL query to retrieve a list of customers whose lastname begins with the letter 'W' or 'w'. Schema The query will run against the customer table, defined as follows: customer_id : INTEGER firstname : VARCHAR(50) lastname : VARCHAR(50) birth_date : DATE address : VARCHAR(255) zipcode : VARCHAR(5) city : VARCHAR(50) phone_number : VARCHAR(20) Required Output The output must contain exactly two columns in the following order: lastname firstname The result set must be ordered alphabetically in ascending order by lastname , and then by firstname in ascending order. Constraints or Notes The first letter filter must be evaluated in a case-insensitive manner. The ascending alphabetical sort must also be evaluated in a case-insensitive manner (e.g., 'walters' comes before 'WHITTARD'). If multiple customers share the exact same first and last name, all matching records must be preserved (do not remove duplicates). Standard SQL is sufficient to solve this problem. Exam