SQL Lesson Queries


#1

Using the BETWEEN operator, write a query that selects all information about movies whose name begins with the letters ‘D’, ‘E’, and ‘F’?

SELECT name
FROM movies
WHERE name
BETWEEN 'D' AND 'E' AND 'F';

Why doesn’t my code work, and I posted the original question before my code. Thank you in advance for your help.


#2

Hi @romingart,

The BETWEEN operator only takes two arguments (the outer bounds), and selects everything between those. Since E comes between D and F, you can remove that part.


#3

@zystvan Thank you very for your response.


#4

This topic is solved.