Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Assignment 3 (Chapter 3) The common requirements of all questions are the same. Read each question carefully and submit a query to fulfill for each

image text in transcribed
image text in transcribed
Assignment 3 (Chapter 3) The common requirements of all questions are the same. Read each question carefully and submit a query to fulfill for each question. Also, students need to submit the result of the corresponding query under the query. The query result should be copied and pasted as it is printed on the screen without any modification. If necessary, the column names appearing in the result should be converted appropriately using "AS" statement. Also, assignment has to be written with Microsoft Word for feedback. For technical issue, other formats, such as image, sql, are not appropriate to receive feedback and comments. Don't delete or change questions. You just need to insert both your TEXT query and captured screenshot result under your query. 1. Using SELECT statement with CHR function, Operator, and referring ASCII table, print your FULL name, although the example shows your instructor's first name only. Also, there should be a space between first and last name (10 points). Eg) SELECT CHR(67)||CHR(104)CHR(114) CHR(105)||CHR(115) from dual; Chris SOL Statement Result Screenshot 2. Show all columns from locations table. If value of postal code column is null, then replace null values with "No Postal Code". If value of state province column is null, then replace null values with "No State". (10 points) SQL Statement Result Screenshot 3. Calculate how many days the employees have been employed. You need to show hire_date, current date, and difference between hire_date and current date. (10 points) SOL Statement Result Screenshot 4. Using the NVL function, show the same results of the following select statement. (5 points) SELECT first_name, salary, commission pct. NVL2(commission_pct, salary + salary * commission_pct, salary) compensation FROM employees WHERE first_name LIKE "T%; SQL Statement Result Screenshot 5. Using the CONCAT function, show the same results of the following select statement. (5 points) SELECT last_name || 'll first_name, department_id, job_id FROM employees WHERE department_id = 50 ORDER BY last name, first_name; SQL Statement Result Screenshot 6. Using INSTR function, find employees whose job_id starts with 'SA'.(10 points); SQL Statement Result Screenshot Assignment 3 (Chapter 3) The common requirements of all questions are the same. Read each question carefully and submit a query to fulfill for each question. Also, students need to submit the result of the corresponding query under the query. The query result should be copied and pasted as it is printed on the screen without any modification. If necessary, the column names appearing in the result should be converted appropriately using "AS" statement. Also, assignment has to be written with Microsoft Word for feedback. For technical issue, other formats, such as image, sql, are not appropriate to receive feedback and comments. Don't delete or change questions. You just need to insert both your TEXT query and captured screenshot result under your query. 1. Using SELECT statement with CHR function, Operator, and referring ASCII table, print your FULL name, although the example shows your instructor's first name only. Also, there should be a space between first and last name (10 points). Eg) SELECT CHR(67)||CHR(104)CHR(114) CHR(105)||CHR(115) from dual; Chris SOL Statement Result Screenshot 2. Show all columns from locations table. If value of postal code column is null, then replace null values with "No Postal Code". If value of state province column is null, then replace null values with "No State". (10 points) SQL Statement Result Screenshot 3. Calculate how many days the employees have been employed. You need to show hire_date, current date, and difference between hire_date and current date. (10 points) SOL Statement Result Screenshot 4. Using the NVL function, show the same results of the following select statement. (5 points) SELECT first_name, salary, commission pct. NVL2(commission_pct, salary + salary * commission_pct, salary) compensation FROM employees WHERE first_name LIKE "T%; SQL Statement Result Screenshot 5. Using the CONCAT function, show the same results of the following select statement. (5 points) SELECT last_name || 'll first_name, department_id, job_id FROM employees WHERE department_id = 50 ORDER BY last name, first_name; SQL Statement Result Screenshot 6. Using INSTR function, find employees whose job_id starts with 'SA'.(10 points); SQL Statement Result Screenshot

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

More Books

Students also viewed these Databases questions

Question

Describe the types of power that effective leaders employ

Answered: 1 week ago

Question

Describe how leadership styles should be adapted to the situation

Answered: 1 week ago