PL/SQL - procedure emp_ins
ÀÛ¼ºÀÚ °ü¸®ÀÚ ÀÛ¼º½Ã°£ 2008-01-17 11:49:34
 

set serveroutput on;

create or replace procedure emp_ins
is

        v_empno        emp.empno%TYPE;
        v_ename        emp.ename%TYPE;

BEGIN

        DBMS_OUTPUT.ENABLE;

        SELECT empno, ename
        INTO  v_empno, v_ename
        FROM emp
        WHERE empno='7499';

        INSERT INTO emp
        (empno, ename)
        VALUES (v_empno + 1, v_ename);

        DBMS_OUTPUT.PUT_LINE('µ¥ÀÌÅÍ ÀÔ¡¤Â ¢¯Ï¡¤á ');

END emp_ins;
/


¸ñ·Ï | ÀÔ·Â | ¼öÁ¤ | ´äº¯ | »èÁ¦