declare

 type emp_rec_type is record

(no emp.empno%type

  , name emp.ename%type

, salary emp.sal%type);


 v_emp_rec emp_rec_type;

begin


 select empno, ename, sal into v_emp_rec

 from emp

 where empno = 7788;


 p('EMPNO : ' || v_emp_rec.no);

 p('ENAME : ' || v_emp_rec.name);

 p('SALARY: ' || v_emp_rec.salary);


end;

/

+ Recent posts