From the course: Nail Your SQL Interview
Unlock the full course today
Join today to access over 24,700 courses taught by industry experts.
Querying the table with logical operators IN and BETWEEN - SQL Tutorial
From the course: Nail Your SQL Interview
Querying the table with logical operators IN and BETWEEN
- [Instructor] In this video we're going to cover BETWEEN and IN which are two more keyword operators. BETWEEN returns data that is within a range of values. Whereas IN returns data that is within a list of values. Let's explore these with some examples. So as you can see here, we have code that has our friends' first name, birthdate, clothing sizes, and favorite colors. So we can go ahead and execute this code if you haven't already done so. But I've already done it, and we have our table here that we'll be working with for these exercises. So let's continue down to our first exercise. So, feel free to pause the video at any time to do these exercises on your own and rejoin me when you're ready. (upbeat music) So exercise number one, query the entire table, and we've done that already. We're going to return the first name and shirt size, where the shirt size is in the range of medium, large, extra large, and XXL. And…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
(Locked)
Querying the table with logical operator LIKE6m 31s
-
(Locked)
Querying the table with logical operators IN and BETWEEN4m 58s
-
(Locked)
Working with the COALESCE command3m 20s
-
(Locked)
Challenge: End of year raises with COALESCE1m 17s
-
(Locked)
Solution: End of year raises with COALESCE3m 10s
-
(Locked)
-
-
-