The query that displays names of employees , sex , and evaluation of the salary for each department : a. select ssn , decode(sex,'M','male','female') ) as sex,decode(salary,salary between 10000 and 29999,'low',salary between 30000 and 39999,'medium','high')"level" from employee; O b. select ssn , decode(sex,'M','male' else 'female') ) as sex,decode(salary,salary between 10000 and 29999,'low',salary between 30000 and 39999,'medium','high')"level" from employee; C. select ssn , decode(sex,'M','male','female') as sex ,case when salary between 10000 and 29999 then 'low' when salary between 30000 and 39999 then 'medium' else 'high' end "level" from employee; d. All the above;

Database Systems: Design, Implementation, & Management
12th Edition
ISBN:9781305627482
Author:Carlos Coronel, Steven Morris
Publisher:Carlos Coronel, Steven Morris
Chapter8: Advanced Sql
Section: Chapter Questions
Problem 62P
icon
Related questions
Question

hi i have this database qoustion i need help with it

The query that displays names of employees , sex , and evaluation of the salary for each
department :
a. select ssn , decode(sex, 'M','male','female') ) as sex,decode(salary,salary between 10000 and
29999,'low',salary between 30000 and 39999,'medium','high')"level" from employee;
O b. select ssn , decode(sex,'M','male' else 'female') ) as sex,decode(salary,salary between 10000
and 29999,'low',salary between 30000 and 39999,'medium','high')"level" from employee;
C. select ssn , decode(sex,'M','male','female') as sex ,case when salary between 10000 and
29999 then 'low' when salary between 30000 and 39999 then 'medium' else 'high' end
"level" from employee;
d. All the above;
Transcribed Image Text:The query that displays names of employees , sex , and evaluation of the salary for each department : a. select ssn , decode(sex, 'M','male','female') ) as sex,decode(salary,salary between 10000 and 29999,'low',salary between 30000 and 39999,'medium','high')"level" from employee; O b. select ssn , decode(sex,'M','male' else 'female') ) as sex,decode(salary,salary between 10000 and 29999,'low',salary between 30000 and 39999,'medium','high')"level" from employee; C. select ssn , decode(sex,'M','male','female') as sex ,case when salary between 10000 and 29999 then 'low' when salary between 30000 and 39999 then 'medium' else 'high' end "level" from employee; d. All the above;
The query that displays first name for the employees whose manager's last name is "Wong"
O a. select fname from employee where Iname = "Wong"
O b. select e.fname from empioyee e join employee m on (e.super_ssn = m.ssn) and m.lname =
%3D
"Wong';
O C. select fname from employee e join department d on (e.super ssn = d.mgr_ssn) and
Iname='Wong;
O d. None of the above
Transcribed Image Text:The query that displays first name for the employees whose manager's last name is "Wong" O a. select fname from employee where Iname = "Wong" O b. select e.fname from empioyee e join employee m on (e.super_ssn = m.ssn) and m.lname = %3D "Wong'; O C. select fname from employee e join department d on (e.super ssn = d.mgr_ssn) and Iname='Wong; O d. None of the above
Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Database Environment
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Recommended textbooks for you
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781305627482
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781285196145
Author:
Steven, Steven Morris, Carlos Coronel, Carlos, Coronel, Carlos; Morris, Carlos Coronel and Steven Morris, Carlos Coronel; Steven Morris, Steven Morris; Carlos Coronel
Publisher:
Cengage Learning