salary_incd_20
Sun May 26 2024 17:50:02 GMT+0000 (Coordinated Universal Time)
Saved by
@exam123
DECLARE
threshold_salary NUMBER := 1000; -- You can change this value as needed
BEGIN
-- Using an implicit cursor to update the salary
UPDATE employee
SET sal = sal * 1.2
WHERE sal > threshold_salary;
-- Display the number of rows updated
DBMS_OUTPUT.PUT_LINE(SQL%ROWCOUNT || ' rows updated.');
END;
/
content_copyCOPY
Comments