Write a PL/SQL block to calculate the incentive of an employee whose ID is 110

  • pl/sql

Write a PL/SQL block to calculate the incentive of an employee whose ID is 110.

The following PL/SQL block shows a veriable incentive have been declared and incentive have assigned into this variable.

الأجوبة

DECLARE
  incentive   NUMBER(8,2);
BEGIN
  SELECT salary * 0.12 INTO incentive
  FROM employees
  WHERE employee_id = 110;
DBMS_OUTPUT.PUT_LINE('Incentive  = ' || TO_CHAR(incentive));
END;
/

Sample Output:

Incentive  = 984

Statement processed.

0.00 seconds
هل كان المحتوى مفيد؟

معلومات ذات صلة

تبحث عن مدرس اونلاين؟

محتاج مساعدة باختيار المدرس الافضل؟ تواصل مع فريقنا الان لمساعدتك بتأمين افضل مدرس
ماهو التخصص الذي تبحث عنه؟
اكتب هنا...