0% found this document useful (0 votes)
10 views3 pages

Level3

F7f60d0f7f7

Uploaded by

aryanjasrotia14
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views3 pages

Level3

F7f60d0f7f7

Uploaded by

aryanjasrotia14
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Click the below icons

www.excelprince.com
SQL TEST PAPER
QUERIES (LEVEL 3)

Table Name: Employee


EMPLOYEE_ID FIRST_NAME LAST_NAME SALARY JOINING_DATE DEPARTMENT
1 Jhon Abraham 1000000 01-JAN-13 12.00.00 AM Banking
2 Michael Clarke 800000 01-JAN-13 12.00.00 AM Insurance
3 Roy Thomas 700000 01-FEB-13 12.00.00 AM Banking
4 Tom Jose 600000 01-FEB-13 12.00.00 AM Insurance
5 Jerry Pinto 650000 01-FEB-13 12.00.00 AM Insurance
6 Philip Mathew 750000 01-JAN-13 12.00.00 AM Services
7 TestName1 123 650000 01-JAN-13 12.00.00 AM Services
8 TestName2 Lname% 600000 01-FEB-13 12.00.00 AM Insurance

Table Name: Incentives

EMPLOYEE_REF_ID INCENTIVE_DATE INCENTIVE_AMOUNT


1 01-FEB-13 5000
2 01-FEB-13 3000
3 01-FEB-13 4000
1 01-JAN-13 4500
2 01-JAN-13 3500

1. Get employee details from employee table whose joining month is “January”

2.Get employee details from employee table who joined before January 1st 2013

3. Get employee details from employee table who joined after January 31 st

4.Get employee details from employee table who joined between January 1st and January
31st

5. Get Joining Date and Time from employee table

6. Get difference between JOINING_DATE and INCENTIVE_DATE from employee and


incentives table

7. Get database date


8. Get Last Name from employee table after replacing special character with white space

Database SQL Queries Interview Questions on "SQL Group By Functions"

9.Get department,total salary with respect to a department from employee table.

10. Get department, total salary with respect to a department from employee table order by
total salary descending

11. Get department, no of employees in a department, total salary with respect to a


department from employee table order by total salary descending

12. Get department wise average salary from employee table order by salary ascending

13. Get department wise maximum salary from employee table order by
salary ascending?

14. Get department wise minimum salary from employee table order by salary ascending

You might also like