Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Retrieve the last names of all employees who work in the department that has the employee with the highest salary among all employees. You can

WORKS ON Essn 123456789 123456789 666884444 453453453 453453453 333445555 333445555 333445555 333445555 
 

Retrieve the last names of all employees who work in the department that has the employee with the highest salary among all employees.

You can run your query in MariaDB if you have populated the tables correctly.

SELECT ____________ FROM EMPLOYEE WHERE DNO =

            ( SELECT _____________ FROM EMPLOYEE WHERE SALARY =

                        ( SELECT ____________ (SALARY) FROM ________________ ) )

WORKS ON Essn 123456789 123456789 666884444 453453453 453453453 333445555 333445555 333445555 333445555 999887777 999887777 987987987 987987987 987654321 987654321 888665555 Pno Hours 1 32.5 7.5 40.0 20.0 20.0 10.0 10.0 10.0 10.0 30 30.0 10 10.0 10 35.0 5.0 2 3 1 2 2 3 10 20 30 30 20.0 15.0 NULL 20 20 PROJECT ProductX ProductY ProductZ Pname Computerization Reorganization Newbenefits DEPENDENT Essn 333445555 Alice 333445555 Theodore 333445555 987654321 123456789 123456789 123456789 Dependent_name Joy Abner Michael Alice Elizabeth Pnumber 1 2 3 10 20 30 Sex F M F F LL Plocation Bellaire Sugarland Houston Stafford Houston Stafford Dnum 5 5 5 Bdate 1986-04-05 M 1983-10-25 F 1958-05-03 M 1942-02-28 1988-01-04 1988-12-30 Daughter 1967-05-05 Spouse 4 1 4 Relationship Daughter Son Spouse Spouse Son

Step by Step Solution

3.48 Rating (161 Votes )

There are 3 Steps involved in it

Step: 1

SELECT Lname FROM EMP... blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Fundamentals Of Database Systems

Authors: Ramez Elmasri, Shamkant Navathe

7th Edition

0133970779, 978-0133970777

More Books

Students also viewed these Databases questions

Question

How does index locking resolve the phantom problem?

Answered: 1 week ago