Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Consider the table employee ( empld , name, department, salary ) and the two queries Q 1 , Q 2 below. Assuming that department 5

Consider the table employee(empld, name, department, salary) and the two queries Q1,Q2 below. Assuming that department 5 has more than one employee, and we want to find the employees who get higher salary than anyone in the department 5, which one of the statements is TRUE for any arbitrary employee table? Q1: Select e.empId From employee e Where not exists (Select * From employee s where s.department =5 and s.salary >=e . salary) Q2: Select e.empId From employee e Where e.salary > ANY (Select distinct salary From employee s Where s.department ="5") Q1 is the correct query Q2 is the correct query Q1 and Q2 are not correct queries Q1 and Q2 are correct queries

Step by Step Solution

There are 3 Steps involved in it

Step: 1

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

Beginning VB.NET Databases

Authors: Thearon Willis

1st Edition

1594864217, 978-1594864216

More Books

Students also viewed these Databases questions