PL/SQL Procedure compilation errors
556526Mar 3 2007 — edited Mar 5 2007I am trying to create a procedure GETEMPLOYEES that displays all employee names of EMPLOYEE table on the screen by concatenating all its columns. But, I am getting error.
Employee Table
EMPLOYEE_ID NUMBER(10)
FIRST_NAME VARCHAR2(40)
LAST_NAME VARCHAR2(40)
CREATE OR REPLACE PROCEDURE GETEMPLOYEES AS
ID EMPLOYEE.EMPLOYEE_ID%TYPE,
fNAME EMPLOYEE.FIRST_NAME%TYPE,
lNAME EMPLOYEE.LAST_NAME
AS
BEGIN
SELECT EMPLOYEE_ID INTO ID,
FIRST_NAME INTO fNAME,
LAST_NAME INTO lNAME
FROM EMPLOYEE;
DBMS_OUTPUT.PUT_LINE(ID||fNAME||lNAME);
END;
/
This is giving compilation error. Can you kindly help.
Thanks in advance.