
Beginner-friendly introduction to MySQL and SQL, focusing on understanding how queries work, not just syntax. Learn with guided walkthroughs and practice problems to create and modify databases for real-world use.
Download and install the MySQL community edition for Windows using the web installer, then install the server and MySQL Workbench, configure a root account, and connect to samples with Workbench.
Set up MySQL on macOS by installing the MySQL community server and MySQL workbench, using the DMG installation, configuring the root password, and enabling auto-start.
Learn how to start MySQL Workbench, connect to the server, and explore the interface, then verify the world sample database is installed for beginner SQL practice.
Install and configure the sample databases by downloading world and sakila, extracting them, and executing their schema and data SQL scripts in MySQL Workbench.
Explore what sql is and why we need it: a structured query language for asking databases for specific data, not a programming language, focusing on read operations and practical querying.
Learn to query the world database with SQL in MySQL Workbench, using select, from, and distinct to remove duplicates, and as to rename columns while handling null values.
Practice three SQL select exercises using the city table in the world database to retrieve all data, city names with populations, and distinct districts.
Explore three SQL exercises: select all from city, show name and population, and use distinct to list unique districts, with upcoming lessons on sorting.
Sort query results with order by across multiple columns, choosing ascending or descending orders. Sort by name, continent, and population to organize country data in the world database.
Master filtering SQL results with the where clause using equals, or, and to refine searches by continent or year. Distinguish text values with quotes and numbers without.
Complete four sql exercises using the world database's countries table, applying where clauses and order by as taught, with a downloadable pdf resource for reference.
Practice sql filtering with =, or, and by solving four exercises on continents and country order. Identify african republics and filter independence years 1960 or 1961.
Explore filtering with the where clause using greater than, less than, greater than or equal to, and between, with examples on independence year and population, plus sorting by name.
Practice filtering data in MySQL using greater than, less than, and between with the where clause through five exercises on the country table and the country language table.
Master SQL filtering with where clauses: select countries by life expectancy over 80 and population over 10 million; filter languages between 80 and 90 percent, order by percentage.
Understand not equal to filtering in SQL by using not and brackets to combine criteria, such as continent and life expectancy, and apply these techniques to refined where clauses.
practice seven sql queries using the not keyword to filter criteria on the country table, reinforcing problem-solving over rote syntax with downloadable resources and next-video solutions.
Learn to filter with not and not equal to using where and brackets in MySQL, then apply multi-level ordering by region, name, and government form for European country queries.
Learn to use the in keyword to filter by multiple values, like continents in a list, and combine with other criteria such as surface area to refine SQL queries.
Review end of section 3 by practicing 15 queries on the Australian birds database in MySQL workbench, loading the Australian Birds.sql script, and checking your answers against the PDF solutions.
Use the where clause with the like operator and % wildcards to pattern-match text, combining conditions and noting case insensitivity and numeric range options.
Practice wildcard filtering with like and % in MySQL by solving five exercises on the cities table from the sample database, with a downloadable pdf and upcoming solution walkthrough.
Master MySQL filtering with wildcards using like to find cities starting with t, ending with x, or containing a space, then refine by district and population not ending in zero.
Learn how the underscore wildcard in MySQL matches exactly one character and how to combine it with percent wildcards for pattern matching on country names and populations.
Practice filtering in SQL using the underscore wildcard with like on the city table of the sample database, with four exercise queries and review solutions in the next video.
Learn to filter with wildcards using like with _ and %, select cities six-character names, three-letter starts, districts ending with three-letter words, deduplicate with distinct, and order results by name.
Query null values in a country table using is null and is not null to find records with or without an independence year. Null means no value, not zero.
Complete the end of section review by attempting eight SQL queries on the Australian Birds database. Activate the database schema and use PDF resource with solutions to verify your work.
Master sql mathematical operations, including addition, subtraction, multiplication, division, modulus, and integer division. Learn rounding and format for decimal control and clear output.
Practice four SQL mathematical operations and learn to use the format function with a downloadable file. Follow along as solutions are covered in the next video.
Master SQL practice problems: add ten to life expectancy for Asian countries, convert and format GNP in US dollars for European countries, compute GNP per capita, and explore ordering results.
Learn how to order by an alias using backticks in MySQL, avoid text-based sorting from format, and preserve numeric order with rounding or the underlying calculation.
Explore aggregate functions in MySQL, starting with count, including counting distinct values and handling nulls, to accurately tally groups of data in practical queries.
Practice aggregate functions in SQL by counting cities in the world database, including total cities, cities starting with the letter a, populations between 1 and 2 million, and distinct districts.
Master aggregate functions in MySQL by counting all rows, filtering with like 'A%', using population between constraints, and counting distinct districts in the city table.
Master aggregate functions in SQL by using avg and sum to compute averages and totals, format with commas and zero decimals, and use aliases, rounding, and distinct.
Apply aggregate functions to the city table to compute sum and average: total Buenos Aires district population and average city population in Scotland, plus the average percentage of Spanish speakers.
Explore aggregate functions in SQL, using sum and average across districts and countries, with aliases and step by step problem solving.
Explore min and max aggregate functions in MySQL with examples. See life expectancy in North America and the largest surface area, plus order by and limit usage.
Study this end-of-section review to master eight SQL questions on aggregate functions and math operations, and practice translating questions into the correct columns, sources, and queries.
Explore how to use group by with aggregate functions, such as count, sum, and average, to compute totals by continent and region, with aliases, order by, and query structure.
Practice grouping data with group by in MySQL: count languages per country; limit to four languages with a where clause; find largest city population per district; count heads of state.
Explore grouping data with SQL: group by language to count countries, order by popularity; filter with where in; compute district city populations with max and rank heads of state.
Discover how the having clause filters groups after a group by using aggregate functions like count and average, with the proper order of where, group by, having, and order by.
Practice exercises use having to group data in MySQL. Explore averages by language, district populations by country code, and country surface areas by government form with sorting.
Master grouping data by language, districts, and government forms using having, with avg, sum, and max, plus where and order by to filter and sort results.
Practice end-of-section review with 11 queries on group by and having using the Australian Birds database; download questions and solutions and try before checking answers, see you in section seven.
Learn to combine data from two or more tables using sql joins, including inner, left, and right joins, with examples using employees and branches.
Master inner joins in MySQL by matching fields across tables, using where and on clauses, and avoiding cross joins. See city and country examples with aliases to illustrate proper matching.
Practice inner joins across languages and countries to list languages per country, count official languages, and show capitals starting with a and southern european cities with population over a million.
Explore inner join solutions across country, language, and city tables, including official languages, counts by country, capitals starting with A, and southern european city populations.
Master left and right joins, showing records from the left or right table with matching data or nulls. Understand counting nulls: count(field) ignores nulls; use count(*) to count all rows.
Explore self joins by pairing records in the same country table with aliases and an inner join on head of state, then remove duplicates via alphabetical name comparison.
practice exercises on left, right, and self joins using city, country, and district data to count cities by independence year, list districts with countries, and generate home and away matchups.
Practice left, right, and self joins on city and country data to reveal independence years, counts by year, and district matchups.
Learn how to join three tables in sql to list each country with its capital city and official languages, using inner joins and left or outer joins.
Practice selecting from three tables to show cities and continents for countries where French is spoken by more than a quarter of the population, and master joins.
Join three tables: city, country, and country language on the country code to list all cities and their continents where French exceeds 25 percent.
Master multi-table joins in sql using the sakila database, linking films, actors, and the film actor table, plus inventory and rentals, with aggregates and where clauses.
Explore subqueries in SQL, including inner and outer queries, nesting up to three levels, linking country, language, and city data. Compare with joins and performance implications.
Master subqueries on world database using inner and outer queries to display districts in Australia, languages in largest african country by surface area, and countries with more languages than Mexico.
Master SQL by solving multi-level subqueries to list Australian districts, languages in the largest country in Africa, and countries with more languages than Mexico.
Learn how to combine two queries with union in MySQL, ensure matching column counts, alias columns, and note that duplicates are dropped by default (use union all for duplicates).
Practice the union operator by combining queries to show continents and regions in a column named areas. Add a second column area type to indicate continent or region, including duplicates.
Learn how to combine query results using union and union all in mysql, create an areas column for continents and regions, and list countries starting with m alongside five-letter cities.
practice using subqueries and unions in the sakila database with end-of-section review tasks, counting actors, matching films by length, listing names, and combining roles across customers, staff, and actors.
Learn MySQL data types, including char, varchar, text, and enum, plus numeric and date/time types, and preview primary keys and foreign keys for future table design.
Learn how primary keys provide unique identifiers and how foreign keys link tables to form relationships, enabling joins; also cover nulls, defaults, and auto-increment in table design.
Create simple pet store tables in MySQL, including pets, staff, and customers with primary keys, and preview foreign keys in the upcoming sales table within the Pet Dash Store schema.
Create a sales table with a primary key sale_id, auto-incremented, not null, and foreign keys to pet_id, staff_id, and customer_id, plus a sale_date, with a default staff_id of S0001.
Create a new database schema with two tables for an ice cream store: stock and sales. Set primary and foreign keys, choose data types, and default quantity to 1.
Create an ice cream schema with two tables. Define stock as code varchar(10) primary key; define sales as id auto-increment with a foreign key to stock(code) and default quantity 1.
Learn how to insert records into the pets table using insert into, specify columns and values, and apply auto increment, default values, current date, enforcing referential integrity with foreign keys.
Update existing records with SQL by using update, set, and where to target rows, with examples on staff and pets tables showing email and price changes.
Learn how to delete rows with where clauses, handle foreign key constraints to maintain referential integrity, and drop entire tables in MySQL basics to beyond.
Practice inserting records, updating prices, flavor names, and stock in an ice cream database across two tables. Check foreign key constraint, perform deletions, and drop the tables.
Master inserts, updates, and deletes in MySQL by manipulating stock and sales tables, enforcing foreign key constraints, auto increment IDs, and basic data modifications.
Explore built-in MySQL date and time functions, including current date and time, date diff for age calculations, and extracting day names or other date parts.
Showcase cascading in MySQL by enabling on delete cascade and on update cascade, demonstrating how parent deletes or updates cascade to child records in stock and sales.
Learn to alter tables with the alter command, including adding columns, changing data types, dropping columns, and renaming columns or tables.
Discover how sql operates behind the scenes in real-world apps, from php and Python code executing select queries to searching flights or shopping catalogs on websites.
Do you want to learn SQL by starting at the very start?
Do you want to be able to confidently write SQL queries to analyse and make sense of data?
Do you want to get started but don't even know what software you need?
Have you tried to learn SQL but got lost along the way?
Or are you a developer who needs to add SQL to their skillset?
This course is for you.
With a student-centred approach, this course will give you the skills and confidence in SQL and MySQL that you need.
I am a qualified and experienced IT educator with over a decade of teaching experience.
I understand students, so when creating this course I focused on two things:
clear and logical explanations
plenty of opportunities for you to practice what we are learning.
You will not just be watching videos of me typing in SQL queries. After every technique is explained, you will learn by doing.
This course includes over 130 practice exercises with full solutions, fully explained.
It is also fully captioned so you can learn without needed your sound turned on.
What are other students saying about the course?
"Excellent and well prepared materials. Exercises are a MUST in my opinion and this course fulfills this criteria for me."
"Having the exercises and solutions explained is a huge help. Thank you!"
"Well explained."
"If anyone wants to learn MySQL from scratch, then you are in the right place."
"Teaching methodology with examples is just enough to understand for a person who will be starting from very scratch . You are the best."
Why learn SQL?
SQL is one of the most in-demand IT skills worldwide. SQL is necessary for web development, app development, writing applications or games, database administration, ecommerce and more. It's a great way to improve your employability, advance your career and boost your earnings potential.
Does the course cover SQL or MySQL?
MySQL is the most popular variant of SQL and it is what we will use in this course. However, the majority of everything that we learn will be directly transferrable to other SQL products such as Oracle, SQLite, Postgres or SQL Server.
Do I need to have SQL set up on my computer to take this course?
No! I will step you through downloading MySQL, MySQL Workbench and the required sample databases. It's all free and easy to use.
What if I need help?
I am highly responsive to any questions you may have along the way. In addition to this, you can join the Code Lift Off course group on Facebook to discuss what you are learning.
Let's go!
After completing this course, you will be able to confidently write SQL queries on any database as well as create databases from scratch.
You will have a solid understanding of how the different SQL commands work, and how to approach various real world problems.
Enough talk, let's go! Sign up and we'll get started!