87.0k views
5 votes
What does the following SQL statement return? SELECT * FROM Employees WHERE EmployeeName LIKE 'a%'

a) Employees whose names start with 'a'
b) Employees whose names end with 'a'
c) Employees whose names contain 'a' anywhere
d) No employees will be returned

1 Answer

2 votes

Final answer:

The SQL statement in question will return employees from the Employees table whose names start with the letter 'a'.

Step-by-step explanation:

The SQL statement SELECT * FROM Employees WHERE EmployeeName LIKE 'a%' will return a set of records from the Employees table. Specifically, it returns employees whose names start with 'a'. The LIKE operator in SQL is used to search for a specified pattern in a column, and when combined with the wildcard character '%', it matches any sequence of characters. In this case, because the 'a%' pattern is specified, SQL will search for any EmployeeName that begins with the letter 'a' followed by any number of characters.

User NYCBilly
by
8.3k points
Welcome to QAmmunity.org, where you can ask questions and receive answers from other members of our community.