13.6k views
3 votes
The CFO of company ABC wants to give every employee a 3% raise, but would like a report to confirm if this is possible. Write an SQL statement that would pull this report from the Employee table. They are requesting just the Employee ID, Current Salary, and Salary plus 3%. Salary is saved in the database for the employees annual pay.

User Duilio
by
3.0k points

1 Answer

1 vote

Answer:

For such a report , the sql query required would be:

SELECT emp_id, curr_salary, curr_salary*1.03 AS inc_salary FROM Employee;

Step-by-step explanation:

For such a report , the sql query required would be:

SELECT emp_id, curr_salary, curr_salary*1.03 AS inc_salary FROM Employee;

In the above sql query employee id is emp_id , curr_salary is the current salary column. "curr_salary*1.03" is been made because an increment of 3% means salary + salary*3% , that is , salary*1.03.

User Aked
by
3.9k points