Learn & Practice SQL Complex Queries | 10 examples (Must DO for Interviews)
HTML-код
- Опубликовано: 5 сен 2022
- In this video, we practice writing SQL Complex queries.
Below are the SQL Queries with their timelines -
1- Find employees with highest salary in a department - 1:27:36
2- Find employees with salary lesser than department average - 9:06:80
3- Find employees with less than average salary in dept but more than average of ANY other Depts - 11:50:16
4- Find employees with same salary - 15:42:90
5- Find Dept where none of the employees has salary greater than their manager's salary - 20:06:16
6- Find difference between employee salary and average salary of department - 25:41:96
7- Find Employees whose salary is in top 2 percentile in department - 28:02:56
8- Find Employees who earn more than every employee in dept no 2 - 31:19:63
9- Department names(with employee name) with more than or equal to 2 employees whose salary greater than 90% of respective department average salary - 35:41:40
10- Select Top 3 departments with at least two employees and rank them according to the percentage of their employees making over 100K in salary - 43:52:66
All the material related to this video can be found here -
know-star.blogspot.com/2022/0...
Best Data Science / Analytics / SQL courses
Learn SQL Basics for Data Science Specialization
imp.i384100.net/qnXYk5
Data Science Fundamentals with Python and SQL Specialization
imp.i384100.net/mgVYre
Please do not forget to like, subscribe and share.
For enrolling and enquiries, please contact us at
Website - knowstar.org/
Instagram - / learn.knowstar
Facebook - / knowstartrainings
Linkedin - www.linkedin.com/company/know...
Email - learn@knowstar.org
Need more tips and pointers to solve SQL Complex queries. Check out our latest video below -
ruclips.net/video/YKHFhZJDw-o/видео.html
I thought sql was tough until I watch this video. Thanks for the wonderful explanation.
Thank you
You the only destination for Datastage developer. I have cleared lots of interviews seeing your videos only. Please add the script for those questions. So that it will be helpful for practice.
Thanks🙏
Thank you. The scripts are available here -
know-star.blogspot.com/2022/09/how-to-write-complex-sql-queries.html?m=1
Great video. Explaining how to think logically is very helpful.
Glad it was helpful!
Excellent explanations. Thank you for sharing
Thank you
Thank you for the video. That is how, step by step, the tasks should be solved!
However, solution #4 is not correct because the number of employees with the same salary can be more than 2. Universal solution:
SELECT EmployeeID
,FullName
,DeptID
,E.Salary
FROM Employees E INNER JOIN (SELECT Salary
FROM Employees
GROUP BY Salary
HAVING Count (Salary) >1) MS ON E.Salary = MS.Salary
Thanks for sharing this. This is a great solution.
Amazing content. Please post more of such detailed videos!
More videos coming soon 👍
Wow , great video as usual and questions were also good. Thanks a lot 🙏
Thank you 🙏
Very useful information. Very helpful for our preparation. Please do more videos like this. Thankyou
Thank you 🙏
Excellent coverage! Looking forward to plenty more queries -- I genuinely love this! Here's hoping that you can create more and more training series -- Basic, Intermediate and Advanced plus super-duper Complex examples! Dhanyawad! AWESOME!
Thank you!
Thank you very much for your effort. I wish you success in your life
Thank you 🙏
Gr8 vdo thnx for ur efforts
Thank You !
2nd question can be solved using co related sub query.
Select e.employeeID, e.DeptID, e.Salary from emp e where e.sal < (select avg(sal) from emp e2 where E1.deptno=e.deptno);
Really very helpful.
Thank you 🙏
Superb!
Thank you 🙏
Good explanation thank you
Thank you 🙏
Hey there,
God bless your efforts.
I have come through the term concurrence in sql, what does it actually means?
Thanks for taking time to clarfifying this to me.
I just subscribed this channel after seeing this video.. Wonderful explanation..
I would suggest to make similar kind of scenarios questions videos playlist for PL/SQL also.
Sure. Glad the video was helpful.
Good
Thank you
I'm getting "Cannot insert explicit value for identity column in table 'Employees' when IDENTITY_INSERT is set to OFF." ERROR
In the syntax of creating the table how you refer the managerId by using empID. I think there is a wrong syntax.
wow
Thank you
great video, you've gained a subscriber, but it will be great to have the scripts so i can tag along, the links in the description isn't going through
Thank you. You can find the sql statements and dataset here - know-star.blogspot.com/2022/09/how-to-write-complex-sql-queries.html?m=1
wow great keep it up, i will be grateful if you could tell how to get this database to my sqlserver so i can practice after watching
sincerly
Thank you.The dataset and sql links are in the description.
in your screen query not visible properly becouse of latest ouput.
All queries are provided in the link in the description box. Hope it helps.
can you pls give me the data set script so that we can try practice
You can find the practice dataset and sql queries here -
know-star.blogspot.com/2022/09/how-to-write-complex-sql-queries.html
Ma'am please reduce size of characters.. can't see full query at a time
Will keep in mind. Thank you for bringing this to our attention.
hi make a video 15 to 20 minutes
Sure, we will be making medium length videos as well 👍
Waise agar Hindi me ki hoti sure like Jayada subscribe hota but English hi without style bolo
your script showing error
Madam tum log style me ku bolte ho jra acche se bolo n
Bhai samajh aarhi toh padhlo warna dusre channel follow krlo...
Inka channel hai inki marzi...