Answered step by step
Verified Expert Solution
Link Copied!
Question
1 Approved Answer

i just need the second question 1) Write a PL/SQL block that extracts and displays the area code, exchange, and line number from a customer's

i just need the second question image text in transcribed
1) Write a PL/SQL block that extracts and displays the area code, exchange, and line number from a customer's phone number. Use the skeleton code provided. DECLARE curr_phone VARCHAR2(30) := *(514) 744-7500"; area_code VARCHAR2( 3); gets assigned 514' below exchange -- gets assigned 744' below Tine_num -- gets assigned 7500' below phone_num gets assigned '5147447500 BEGIN area_code :- SUBSTR(curr_phone, ...); exchange :- line_num phone_num --print the phone_num, which has only digits END: Using the given name and salary, complete the PL/SQL, block that calculates a raise using the following formula: If the salary is less than $20k then the raise is $900. If the salary is between $20k and $sok, inclusive, then the raise is 3%. If the salary is above $sok then the raise is 2.75%. On one line of output, give the employee's name, original salary, amount of the raise (in dollars), and the new salary. 2) DECLARE first_name VARCHAR2(30) :- 'Alice' last_name VARCHAR2(30) :-Jones' salary NUMBER(9.2) := 40000; raise new_salary BEGIN dbms_output.put_line(RPAD(first_name, 31) || RPAD.... 31) 11 TO_CHARC ... '59.999,999.99') 11 ...); END

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_2

Step: 3

blur-text-image_3

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

Records And Database Management

Authors: Jeffrey R Stewart Ed D, Judith S Greene, Judith A Hickey

4th Edition

0070614741, 9780070614741

More Books

Students explore these related Databases questions