Use Of GROUP BY Clause In SQL | Interview Questions | Examples

preview_player
Показать описание
In this video we will learn to us GROUP BY Clause in SQL with help of 5 different use cases of Group By Clause along with query practice.

Please Like 👍, Share and Subscribe.

Query PDF To Create Table And Add Data Into Table -

⭐Constraints In SQL | Part-I

⭐Constraints In SQL | Part-II

⭐How To Delete Duplicate Rows In a Table

⭐How To Find Duplicate Rows In a Table

⭐Part 1:Top 9 SQL queries for interview -

⭐Part 2:Top 9 SQL queries for interview -

⭐Find Nth Highest Salary in SQL | 5 Different Ways

⭐Top SQL Interview Question

⭐Find the number of Employees working in each department | SQL

⭐Types of Joins in SQL-

⭐Difference Between WHERE and HAVING Clause

⭐Aggregate Functions In SQL | COUNT, SUM, AVG, MIN, MAX | IFNULL( )

⭐Difference Between DELETE, DROP and TRUNCATE

⭐SQL vs NoSQL | MySQL vs MongoDB

⭐DBMS vs RDMS

⭐Normalization in DBMS-

⭐Types of key in DBMS-

⭐Create MySQL Database and Table -

#sql #GroupByClause #Having #GroupBy #sqlserver #database #mysql #PlacementPreparation
Рекомендации по теме
Комментарии
Автор

answers:
1. select department, max(salary) from employee_info group by department;

2. select gender, count(id) from employee where dob between 01/01/1960 AND 31/12/1975 group by gender;

3. select department, count(id) from employee_info group by department;

Please check my queries @CodeEra :) Thanks

amanrathore
Автор

Thank you so much for giving the vertical view of table after group by is used. The view made it so easy to understand. In no other video I found this. Thank you so much sister.

debasreetenyson
Автор

Thanks for your excellent videos based on scenarios. Helps me a lot

mejawad
Автор

select
department, max(salary) from employee_info group by department;

select
count(*), gender from employees group by gender having dob between
'1960-01-10' and '1975-12-31';

select count(*), department
from employees group by department;

vineelsai
Автор

very well structured lecture
Explained thoroughly

pradyumansinghshekhawat
Автор

Very helpful and you explain in very simple manner . Thank you👍

stereolyrics
Автор

Null value it is display y as its sum is less than 17 k in the vedio at 10.20

entertaintvshorts
Автор

Great work..Pls take full SQL course from beginners.. it is very useful to them to crack the interview

potnurinagamohan
Автор

1) select max(Salary), department
from employee_info
group by department;
2) select count(ID), gender from employee_info
where DOB between 01/01/1960 and 31/12/1975
group by gender;
3)select count(ID), department from employee_info
group by department;

AnjaliMathur-drui
Автор

TQQ madam very useful &easy to understand

gollangianand
Автор

Madam for practice purspose can you plz provide more questions on sql

kiranharijan
Автор

Hello,
Hello, Great work you are doing in computer training.
I am generating reports and i have challenges in using using sum and group by in my sql querries.
Could you kindly offer some help i am stuck on these .
Your help is much appreciated.
David

davidlewisn
Автор

Is it always necessary to include those columns in "group by" which are used after Select?
For ex: Select col1, col2 from table group by col1.
In this above query do we also need to include col2 in group by as it is there after Select.
Could you please confirm this point.

adeshtiwari
Автор

why in the output result at 11.25, NULL is not displayed although it has sum(salary) as 87000 which is greater than 17000

tapantiwari
Автор

Why using aggrigate function in group by

sujin
Автор

there is a small mistake in data set constraint cant be "NOT NULL" while creating table .

bharatkumarboddepalli