Multiple choice technology databases

You need to display the last names of those employees who have the letter “A” as the second character in their names. Which SQL statement displays the required results?

  1. SELECT last_name FROM EMP WHERE last_name LIKE ‘_A%’;

  2. SELECT last_name FROM EMP WHERE last name =’*A%’

  3. SELECT last_name FROM EMP WHERE last name =’_A%’;

  4. SELECT last_name FROM EMP WHERE last name LIKE ‘*A%’

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The pattern '_A%' uses underscore as a wildcard for exactly one character, followed by 'A', then percent for any sequence. This matches names where 'A' is the second character. Options B, C, D use incorrect syntax (spaces in column name, equals instead of LIKE, asterisk which isn't a SQL wildcard in this context).