πŸ” MySQL Practice Day – Clauses, Conditions & Fun with Queries

TheTansihTheTansih
3 min read

Today was a super fun and insightful day in my MySQL journey πŸ˜„. Under the amazing guidance of Shafiq Sir, I revised some core MySQL concepts with hands-on experience β€” and trust me, learning this way feels different! No just theory, only practical magic πŸ’»βœ¨.

🧠 What I Practiced Today

Here’s what I revised and implemented step-by-step:

1️⃣ Creating a Simple Table

I created a basic student table with first and last name fields. Simple structure, but a great way to get hands-on with CREATE TABLE.

πŸ“Œ Example: I created a table for students with fields like First Name and Last Name.

2️⃣ Inserting Data

Added multiple entries into the table, including a row where the last name was missing. This helped me understand how MySQL handles NULL values.

πŸ“Œ Example: I inserted a student named "Haero" with no last name.

3️⃣ Selecting Data

Used a SELECT * FROM student to view all records. It's always a satisfying moment to see the data you added show up right there! πŸ”

4️⃣ Using LIKE and LOWER()

Tested out the LIKE operator, which is case-sensitive in MySQL. I used LOWER() to make the search smoother.

πŸ“Œ Example: I searched for all first names starting with 'T' (like "Tani") using LIKE after converting names to lowercase.

5️⃣ Conditional Display with CASE

Explored the CASE statement to handle NULL values gracefully.

πŸ“Œ Example: If the last name is missing, I showed a custom message like β€œNo name sorry”; otherwise, a fun message like β€œnAME NAME EHEH”.


πŸ’‘ Learnings of the Day

  • βœ… LIKE is case-sensitive in MySQL. To perform a case-insensitive search, use LOWER() or UPPER().

  • βœ… Handling NULL values smartly makes your results more readable.

  • βœ… Real-world SQL is not just about queries β€” it’s about clean data handling and logic-building.

  • βœ… Hands-on practice > theory-only learning!


πŸ“š Resources & Guidance

πŸŽ₯ Covered 3 videos from a 7-part industry-level SQL series (shared by Shafiq Sir). These videos are focused on real-world applications, not just textbook definitions.

πŸ‘¨β€πŸ« Huge shoutout to my mentor Shafiq Sir πŸ™ β€” thank you for making learning enjoyable and practical!


✨ My Thoughts

Learning SQL this way β€” by practicing, making mistakes, correcting them, and reflecting β€” has completely changed my mindset. Earlier it felt technical, now it feels powerful πŸ’ͺ.

I used to think SQL was just for querying β€” now I see it as a conversation with data.


🧾 Quote of the Day

"Tell me and I forget. Teach me and I remember. Involve me and I learn." β€” Benjamin Franklin


Radhe Radhe 🌸
Happy Learning,
– Tanish

0
Subscribe to my newsletter

Read articles from TheTansih directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

TheTansih
TheTansih