TheAnalyst / SQLAll lessons ↗
Day 1 · Core SQL · 10–15 minutes

Choose columns.
Filter rows.

Today you’ll use SELECT to choose what to see and WHERE to decide which records belong in the result.

01 · Learn

Two questions make a query

Which columns do I need? Use SELECT. Which rows qualify? Use WHERE. Text values need single quotes; numbers usually do not.

SELECT name, country
FROM customers
WHERE country = 'India';
Read it in plain English

From the customers table, return each person's name and country, but only for rows where country is India.

02 · Remember

Recall before you practise

Without looking above, complete this sentence: SELECT chooses ______; WHERE filters ______.

03 · Solve

Write and run SQL

Task: return the name and country of customers from India. Sort names alphabetically. You can edit the starter query or clear it and write your own.

Loading browser SQL engine…
04 · Keep it

One-minute recap

Tomorrow’s lesson can build on this without replacing today’s page. Bookmark this page and return to it for review.