Explains an alternative (generally less recommended) method to retrieve data from one table based on a filter placed on another table
- [Instructor] We've seen the IN keyword already…for filtering.…So we can write for example select star from actor,…where field name is IN and then we supply a list of…matching values.…Or actually, we can put a second select statement into…these brackets so that we are returning data from one table…based on records in another.…Generally, it's neater and quicker to use joins but there…are times when you might want to use this method,…so let's give it a go.…
We're going to get all the rental details where the…customer name is Jennifer.…So what we'll do, select star from rental, and we put the…rental table first because this is the one that we want…to return data from.…And then we say where customer ID is in,…and we delete all of those and we write a whole new…select statement, select customer ID from customer where…first name is Jennifer.…
And that's returned as 28 rows there, so there have been…28 rentals made by a customer with a first name of Jennifer.…So we're filtering customer ID based on customer name,…and then we return that in a format that the first query…
Join Emma Saunders as she shows you how to design and write simple SQL queries for data reporting and analysis. Review the different types of SQL, and then learn how to filter, group, and sort data, using built-in SQL functions to format or calculate results. Learn a bit about data types and database design. Discover how to perform more complex queries, such as joining data together from different database tables. Last but not least, Emma shows how to save your queries as views, so you can run them again and again.
- Using different versions of SQL
- Retrieving data with SELECT statements
- Filtering and sorting your results
- Transforming results with built-in SQL functions
- Grouping SQL results
- Merging data from multiple tables
- Identifying data types, and how to make sense of your database design
- Saving SQL queries
Skill Level Intermediate
Data Visualization for Data Analystswith Bill Shander1h 31m Beginner
1. Use SQL to Report Data
Data types in SQL databases5m 47s
2. Group your SQL Results
3. Merge Data from Multiple Tables
4. Advanced Features and Taking Your Learning Forwards
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.