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!

Getting error ORA-06550: Line 1, Column 7: PL/SQL: Statement ignored 06550. 0000 -"line %s, column %

3554153Sep 27 2017 — edited Sep 28 2017

I created the below trigger using Oracle 11g (ver 4.1.4)

CREATE OR REPLACE TRIGGER VALIDATE_BDAY_TRIG

BEFORE INSERT ON EMPLOYEE_T

FOR EACH ROW

--DECLARE

  --v_dob  EMPLOYEE_T.EMPLOYEEBIRTHDATE%TYPE;

BEGIN

  INSERT INTO

EMPLOYEE_T (EmployeeID, EmployeeName, EmployeeAddress, EmployeeCity, EmployeeState, EmployeeZip, EmployeeBirthDate, EmployeeDateHired, EmployeeSupervisor)

VALUES (14545-589, 'JAKE', 'PHILIPPINES', 'PHILIPPINES', 'ML', 1113, TO_DATE('11/13/1980', 'MM/DD/YYYY'), TO_DATE('05/27/2017', 'MM/DD/YYYY'), 456789);

    DBMS_OUTPUT.PUT_LINE('DOB: ' || :NEW.EMPLOYEEBIRTHDATE);

END;

/

When I tried to execute it to check if my trigger is correct using the below query:

EXEC VALIDATE_BDAY_TRIG;

I've got the error message:

Error report -

ORA-06550: line 1, column 7:

PLS-00201: identifier 'VALIDATE_BDAY_TRIG' must be declared

ORA-06550: line 1, column 7:

PL/SQL: Statement ignored

06550. 00000 -  "line %s, column %s:\n%s"

*Cause:    Usually a PL/SQL compilation error.

*Action:

My objective is to display the date of birth of the new inserted record so I can use it and validate if the date of birth is valid or not.

Any idea?

Thank you!

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 25 2017
Added on Sep 27 2017
5 comments
5,085 views