Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Issues with procedure!

user782973-OracleJan 19 2015 — edited Jan 20 2015

Hi, Can someone help me understand whats wrong with my procedure.

CREATE OR REPLACE procedure VALID_PROC( START_DATE IN DATE, END_DATE IN DATE)

IS

cursor c1 is

SELECT * FROM EMP

WHERE HIREDATE BETWEEN TO_DATE('01-01-85','DD-MM-YY') AND TO_DATE('01-01-80','DD-MM-YY');

c_row c1%rowtype;

BEGIN

OPEN C1;

fetch c1 into c_row;

if c1%notfound then

endif;

INSERT INTO emp_back(empno,ename,job,mgr,hiredate,sal,comm,deptno)

VALUES(c_row.empno,c_row.ename,c_row.job,c_row.hiredate,c_row.sal,c_row.comm,c_row.deptno);

commit;

close c1;

END;

/

Comments

Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Feb 17 2015
Added on Jan 19 2015
16 comments
8,083 views