top of page

Welcome
to NumpyNinja Blogs

NumpyNinja: Blogs. Demystifying Tech,

One Blog at a Time.
Millions of views. 

Basics Of SQL that actually matters in real time

Jan 13
3 min read

Hello Everyone,

Let me tell you a secret about SQL...

as a beginner I used to think SQL is hard, it needs strong math and coding background but in reality SQL uses simple English words with some common sense. if you can ask questions, you can learn SQL.



Think if SQL is Cupboard and there are lot of documents (Data) in that cupboard.


What do SQL make us learn is:

1) which document to find

2) in which order you have to file or see.

3) and how to count.


that's it ...THIS IS SQL !!!


A) Filtering Data :- only search for important ones.


I will explain you with simple example:

suppose you have lot of pens but you only want fountain pens.

what will you do?

you will leave everything else. right?

SQL also does that.

Filtering Means , I don't want complete data , I just need which is important or is required .


How we use filtering in SQL ?

We use WHERE.


SELECT * FROM students WHERE class = 12;

this query means show all details of only class 12th students and ignore other.

Filtering is very important ,because without filtering , too much data comes and cannot be understood


B) Sorting Data :- To view in the correct order


consider you have lot of numbers for eg...6, 4,2,8,12,,10... if someone try to read or understand these it difficult.

but if we keep it in order 2,4,6,8,10,12 its easy .

In SQL sorting means either u keep in Ascending order or Descending order. we use syntax ORDER BY in SQL for sorting.

Select Name, Marks

from Students

Order By Marks DESC;

This query means students with higher marks comes first and lower marks later

Using sorting we can know who is at top and who comes at end.


C) Aggregation :- Counting and Adding.


Now, suppose you want to know :

how many students are there?

or you want to count total marks.

one one counting will be difficult. SQL makes it easy.

Aggregation means turning lot of data into one answer for eg

Select COUNT(*)

From Students;

this means total how many students are there.

one more Eg : Using Group

Select Class, Count(*)

From Students

Group By Class;

this query will show you how many students are in each class like


Why isn't academic theory necessary?

People often start by explaining:

SQL's history, Difficult definitions, big name... but all this is confusing for beginners like me.

the truth is : if you understand these three things:

WHERE(filter)

ORDER BY (sort)

COUNT/ GROUP BY (count)

then you started to understand SQL and you can progress SQL gradually.


Now you must be thinking why we need it?

Imagine you have an excel file with 50,000 rows.

you want :

only last months data

only students with marks above 75

sorted by highest score


Doing this manually is slow and error-prone.

SQL exists to answer such questions in seconds, no matter how big is the data is.


SQL is like asking questions

SQL is not a programming language in the traditional sense

it is more like asking clear questions.


Bad question : Show me everything.

Good questions: Show me only class 12 students, sorted by marks , and tell me how many there are.


" The better your question, the better your answer"



SQL is not scary ,it is simply a way of asking the right question to your data

if you choose what you need , arrange it properly and count it, you already know the basics of SQL

In the beginning , you do not need complex definitions or heavy theory

understanding WHERE, ORDER BY, and COUNT takes you long ways.

SQL is learned step by step, not all at once.

start small, stay curious and SQL will slowly become your friend !!!




 
 

+1 (302) 200-8320

NumPy_Ninja_Logo (1).png

Numpy Ninja Inc. 8 The Grn Ste A Dover, DE 19901

© Copyright 2025 by Numpy Ninja Inc.

  • Twitter
  • LinkedIn
bottom of page