n Structure Query Information    Select all columns from the jobs table using an asterisk. 2. Select only job title, min salary, and max salary columns from the jobs table. 3. Select all columns from the d_partners table by writing out all of the columns in the select statement. 4. Using the d_partners table, display the id, and then concatenate the first_name and last_name together with a space in between the two columns. Give the concatenated column an alias of NAME. Be sure to use the optional AS keyword. 5. Using the job_grades table, show the grade level, and then subtract the lowest_sal from the highest_sal to show the amount of variance there is for each grade level. Give the calculated column an alias of Salary_Variance. Do not use the optional AS keyword. 6. Using the employees table, show an unduplicated list of department_id’s. 7. Change the SELECT statement you built for question 4, adding a single column called Partner_Information that concatenates the partner’s expertise, auth_expense_amt, and manager_ id, so the output looks like this (note: some 2 of the columns for the partners have no value so it shows up empty in the results.): 8. Each staff’s salary is displayed as their hourly salary in the f_staffs table. Write a query that displays the id, salary, then multiplies that salary by 40, and then multiplies by by 52 to show what the employee’s annual salary would be. Give the calculated column an alias of Annual_Salary. Your results should look like this: 9. Write a query using the dual table to subtract 59874 from 128579 and call the calculated column Calculation. 10. Write a query that displays the name and description for all the events in the DJs on Demand d_events table. The column headings should appear as “Event” and “Description” 11. The employees in the employees table are going to get a 10% a month raise for the year. However, when the president looked at the results, he couldn't figure out why the new raises were not as he predicted. Kochhar should have a new salary of $$18,700, Hunold’s salary should be $9,900, and De Ernst’s should be $6,600. He used the following query: select last_name, salary * .10 as New_Salary from employees What should he have done? Show me the corrected code and the results.

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
icon
Concept explainers
Question

In Structure Query Information 

 

Select all columns from the jobs table using an asterisk.
2. Select only job title, min salary, and max salary columns from the jobs table.
3. Select all columns from the d_partners table by writing out all of the columns in
the select statement.
4. Using the d_partners table, display the id, and then concatenate the first_name
and last_name together with a space in between the two columns. Give the
concatenated column an alias of NAME. Be sure to use the optional AS
keyword.
5. Using the job_grades table, show the grade level, and then subtract the
lowest_sal from the highest_sal to show the amount of variance there is for each
grade level. Give the calculated column an alias of Salary_Variance. Do not
use the optional AS keyword.
6. Using the employees table, show an unduplicated list of department_id’s.
7. Change the SELECT statement you built for question 4, adding a single column
called Partner_Information that concatenates the partner’s expertise,
auth_expense_amt, and manager_ id, so the output looks like this (note: some
2
of the columns for the partners have no value so it shows up empty in the
results.):
8. Each staff’s salary is displayed as their hourly salary in the f_staffs table. Write
a query that displays the id, salary, then multiplies that salary by 40, and then
multiplies by by 52 to show what the employee’s annual salary would be. Give
the calculated column an alias of Annual_Salary. Your results should look like
this:
9. Write a query using the dual table to subtract 59874 from 128579 and call the
calculated column Calculation.
10. Write a query that displays the name and description for all the events in
the DJs on Demand d_events table. The column headings should appear as
“Event” and “Description”
11. The employees in the employees table are going to get a 10% a month
raise for the year. However, when the president looked at the results, he couldn't
figure out why the new raises were not as he predicted. Kochhar should have a
new salary of $$18,700, Hunold’s salary should be $9,900, and De Ernst’s
should be $6,600. He used the following query:
select last_name, salary * .10 as New_Salary
from employees
What should he have done? Show me the corrected code and the results.

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 6 steps

Blurred answer
Knowledge Booster
Query Syntax
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.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education