- Популярные видео
- Авто
- Видео-блоги
- ДТП, аварии
- Для маленьких
- Еда, напитки
- Животные
- Закон и право
- Знаменитости
- Игры
- Искусство
- Комедии
- Красота, мода
- Кулинария, рецепты
- Люди
- Мото
- Музыка
- Мультфильмы
- Наука, технологии
- Новости
- Образование
- Политика
- Праздники
- Приколы
- Природа
- Происшествия
- Путешествия
- Развлечения
- Ржач
- Семья
- Сериалы
- Спорт
- Стиль жизни
- ТВ передачи
- Танцы
- Технологии
- Товары
- Ужасы
- Фильмы
- Шоу-бизнес
- Юмор
Aggregate Functions in SQL | Learn with Mr. Kiran Jadhav
Aggregate Functions in SQL-
Aggregate functions in SQL perform calculations on a set of values and return a single value. They are commonly used with the GROUP BY clause to perform operations on grouped data.
There are 5 Aggregate Functions in SQL- MIN, MAX, AVG, SUM & COUNT
MIN- Returns the lowest value in a column
MAX- Returns the highest value in a column
AVG- Returns the average value of a numeric column
SUM- Returns the total sum of a numeric column
COUNT- Returns the number of rows that match a specified condition
-- Aggregate Functions- MIN, MAX, AVG, SUM, COUNT
-- MIN
SELECT MIN(empsalary) FROM employee
-- select empname, empsalary from employee where empsalary = (SELECT MIN(empsalary) FROM employee)
-- MAX
SELECT MAX(empsalary) FROM employee
-- select empname, empsalary from employee where empsalary = (select max(empsalary) from employee)
-- AVG
SELECT AVG(empsalary) FROM employee
-- SUM
SELECT SUM(empsalary) FROM employee
-- COUNT
SELECT COUNT(empid) FROM employee
-- 2nd largest salary from employee
SELECT MAX(empsalary) FROM employee WHERE empsalary NOT IN (SELECT MAX(empsalary) FROM employee)
SELECT empname, empsalary FROM employee WHERE empsalary=(SELECT MAX(empsalary) FROM employee WHERE empsalary NOT IN (SELECT MAX(empsalary) FROM employee)
)
-- Department wise Sum of salary
SELECT empdept, SUM(empsalary) FROM employee GROUP BY empdept
-- Department wise Avg salary
SELECT empdept, AVG(empsalary) FROM employee GROUP BY empdept
💻 Stay ahead in 2025 and beyond!
📢 Don't forget to like, share, and subscribe for more insightful content.
Visit fullstackjavadeveloper.in for more details and enrollment opportunities.
#CoreJava #JDK8Features #Java #Fullstack #FullStackJavaDeveloper #SpringBoot #SoftwareDevelopment
Connect with us:
Call or WhatsApp: +91 7887575991 / 020 47212644 [24/7 Support]
Visit: fullstackjavadeveloper.in
Facebook - https://www.facebook.com/fullstackjavadeveloper/
LinkedIn - https://www.linkedin.com/company/full-stack-java-developer-pune
Instagram - https://www.instagram.com/fullstackjavadeveloper/
Meet Mr. Kiran Jadhav :
Software Architect | Full Stack Book Author | Technical Keynote Speaker
LinkedIn - https://www.linkedin.com/in/kiran-jadhav-22649b99/
guys if you like this video please do subscribe now and press the bell icon to not miss any update from Full Stack Java Developer, Pune
#CodeDeployment #JavaApp #Programming #DevLife #TechTips #FileManagement #Coding #OpenSource #Java #TechTutorial #DeveloperCommunity #JavaProjects #LearnToCode #AppDevelopment #WebDevelopment #TechEducation #like #share #comment
Disclaimer/Policy:
--------------------------------
Note: All uploaded content in this channel is mine and it’s not copied from any community, you are free to use source code from above mentioned GitHub account
Видео Aggregate Functions in SQL | Learn with Mr. Kiran Jadhav канала Full Stack Java Developer
Aggregate functions in SQL perform calculations on a set of values and return a single value. They are commonly used with the GROUP BY clause to perform operations on grouped data.
There are 5 Aggregate Functions in SQL- MIN, MAX, AVG, SUM & COUNT
MIN- Returns the lowest value in a column
MAX- Returns the highest value in a column
AVG- Returns the average value of a numeric column
SUM- Returns the total sum of a numeric column
COUNT- Returns the number of rows that match a specified condition
-- Aggregate Functions- MIN, MAX, AVG, SUM, COUNT
-- MIN
SELECT MIN(empsalary) FROM employee
-- select empname, empsalary from employee where empsalary = (SELECT MIN(empsalary) FROM employee)
-- MAX
SELECT MAX(empsalary) FROM employee
-- select empname, empsalary from employee where empsalary = (select max(empsalary) from employee)
-- AVG
SELECT AVG(empsalary) FROM employee
-- SUM
SELECT SUM(empsalary) FROM employee
-- COUNT
SELECT COUNT(empid) FROM employee
-- 2nd largest salary from employee
SELECT MAX(empsalary) FROM employee WHERE empsalary NOT IN (SELECT MAX(empsalary) FROM employee)
SELECT empname, empsalary FROM employee WHERE empsalary=(SELECT MAX(empsalary) FROM employee WHERE empsalary NOT IN (SELECT MAX(empsalary) FROM employee)
)
-- Department wise Sum of salary
SELECT empdept, SUM(empsalary) FROM employee GROUP BY empdept
-- Department wise Avg salary
SELECT empdept, AVG(empsalary) FROM employee GROUP BY empdept
💻 Stay ahead in 2025 and beyond!
📢 Don't forget to like, share, and subscribe for more insightful content.
Visit fullstackjavadeveloper.in for more details and enrollment opportunities.
#CoreJava #JDK8Features #Java #Fullstack #FullStackJavaDeveloper #SpringBoot #SoftwareDevelopment
Connect with us:
Call or WhatsApp: +91 7887575991 / 020 47212644 [24/7 Support]
Visit: fullstackjavadeveloper.in
Facebook - https://www.facebook.com/fullstackjavadeveloper/
LinkedIn - https://www.linkedin.com/company/full-stack-java-developer-pune
Instagram - https://www.instagram.com/fullstackjavadeveloper/
Meet Mr. Kiran Jadhav :
Software Architect | Full Stack Book Author | Technical Keynote Speaker
LinkedIn - https://www.linkedin.com/in/kiran-jadhav-22649b99/
guys if you like this video please do subscribe now and press the bell icon to not miss any update from Full Stack Java Developer, Pune
#CodeDeployment #JavaApp #Programming #DevLife #TechTips #FileManagement #Coding #OpenSource #Java #TechTutorial #DeveloperCommunity #JavaProjects #LearnToCode #AppDevelopment #WebDevelopment #TechEducation #like #share #comment
Disclaimer/Policy:
--------------------------------
Note: All uploaded content in this channel is mine and it’s not copied from any community, you are free to use source code from above mentioned GitHub account
Видео Aggregate Functions in SQL | Learn with Mr. Kiran Jadhav канала Full Stack Java Developer
Комментарии отсутствуют
Информация о видео
27 марта 2025 г. 15:30:06
00:16:50
Другие видео канала




















