๐๐น๐ฎ๐๐ ๐ฑ & ๐ฒ ๐๐ถ๐๐ต ๐๐ผ๐ต๐ผ๐ฟ๐ ๐ณ: ๐๐ค๐ ๐ ๐ฎ๐๐๐ฒ๐ฟ๐.
After teaching students how to design databases (DDL) and populate them (DML), we dove deep into the part everyone actually uses daily: querying data.
DQL - Data Query Language. This is where the magic happens.
๐ข๐ฝ๐ฒ๐ฟ๐ฎ๐๐ผ๐ฟ๐
Students learned how to filter and find exactly what they need:
โ Arithmetic operators ( , -, *, /) - calculating discounts, totals, profit margins
โ Comparison operators (=, >, <, >=, <=) - finding patients above a certain age, bills over a threshold
โ Logical operators (AND, OR, NOT) - combining multiple conditions
โ LIKE - searching for patterns in names, emails, addresses
โ IN & BETWEEN - filtering ranges and specific lists
โ IS NULL / IS NOT NULL - finding missing data
This isnโt theory. Students used these to answer real questions: โShow me all patients over 45 with unpaid billsโ or โFind all visits scheduled this week in the Cardiology department.โ
๐๐ด๐ด๐ฟ๐ฒ๐ด๐ฎ๐๐ฒ ๐๐๐ป๐ฐ๐๐ถ๐ผ๐ป๐
Then we moved into summary statistics:
โ SUM - total revenue, total payments
โ AVG - average consultation fee, average bill amount
โ COUNT - number of visits, number of patients
โ MIN & MAX - lowest and highest values
They learned GROUP BY to break down data by categories: โWhatโs the total revenue per department?โ or โHow many patients visited each doctor?โ
๐๐๐ฉ๐๐ก๐ ๐๐น๐ฎ๐๐๐ฒ
WHERE filters rows before grouping.
HAVING filters groups after aggregation.
Students learned when to use each: โShow me departments with more than 5 doctorsโ or โWhich doctors have average consultation fees above โฆ30,000?โ
This is where beginners usually get stuck. Not anymore.
๐ง๐ฒ๐
๐ ๐๐๐ป๐ฐ๐๐ถ๐ผ๐ป๐
Finally, we covered string manipulation:
โ CONCAT - combining first and last names
โ UPPER/LOWER - standardizing text
โ TRIM - cleaning up messy data
โ SUBSTRING - extracting parts of text
โ LEN - counting characters
Real-world use: cleaning patient names, formatting phone numbers, extracting area codes.
๐ง๐ต๐ฒ ๐ฟ๐ฒ๐๐๐น๐?
Students went from โHow do I select data?โ to writing complex queries that answer actual business questions.
Theyโre not just running SELECT * anymore.
Theyโre filtering 20,000 patient records to find exactly what matters.
Theyโre calculating revenue by department.
Theyโre identifying trends in visit patterns.
Theyโre solving real problems.
This is what happens when you combine structure, real projects, and hands-on practice.
Cohort 8 starts this sunday. Last chance to join.
๐
selar.com/7q7p1y224k
๐ฑ 234 911 028 9203
#SQL #DataAnalysis #DataWithDanny #Datafam