Sobes.tech
Junior — Senior

Efficient index selection for queries to a large table

livecode

Task condition

There is a table named User in the database containing about 10 million records, and it lacks indexes. It is required to suggest the optimal index (or set of indexes) that will speed up the execution of the following query.

SELECT email, firstName, lastName, role
FROM User
WHERE firstName = ? AND lastName = ?;