Question: A) Create a SQL procedure to calculate the following: I. Salay increase of employees for a given department (The procedure should accept 2 variables. First
A) Create a SQL procedure to calculate the following:
I. Salay increase of employees for a given department (The procedure should accept 2 variables. First one is a % increase in salary and second variable is a department number.)
The output should display all the employees in the department with the old salary and new salary.
II. Create a stored procedure to display given number of rows from Employee table. (The variable should be how may records you want to display.)
The result is to show only that records you requested.
B. Create a user defined function to calculate the tax of an employee. (The function should take in a number as tax % and calculate how much the employee should pay as a tax.)
Display salary and tax as 2 columns and display only top 10 employee.
C. Create a stored procedure to immulate a simple "Calculator" with the following function.
I. ADD 2 numbers, II. Substract 2 numbers, III. Divide 2 Numbers, IV. Multiply 2 numbers
*Note: Accept a Calculation symbol, 2 numbers and display the result.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
