%rowtype problem
613695Jan 2 2008 — edited Jan 3 2008Hi, i have to consult a DB and the result i have to construct a %rowtype.
I tried several times and alvway get the same problem. Even, i tried with a simplier consult to verify, but i get the same result. The code for the easiest procedure is:
DECLARE
TYPE informe_multiservicios_type IS REF CURSOR RETURN i_m_row%ROWTYPE;
informe_multiservicios informe_multiservicios_type;
i_m_fila i_m_row%ROWTYPE;
BEGIN
OPEN informe_multiservicios FOR
SELECT
ABREVIATURA --Tipo documento
FROM
NU_TIPOS_IDENTIFICACION;
LOOP
FETCH informe_multiservicios INTO i_m_fila;
EXIT WHEN informe_multiservicios%NOTFOUND;
dbms_output.put_line(i_m_fila.ABREVIATURA);
END LOOP;
CLOSE informe_multiservicios;
END;
I got the following error from TOAD:
ORA-06550: line 2, column 56:
PLS-00201: identifier 'I_M_ROW' must be declared
ORA-06550: line 2, column 2:
PL/SQL: Item ignored
ORA-06550: line 5, column 11:
PLS-00201: identifier 'I_M_ROW' must be declared
ORA-06550: line 5, column 11:
PL/SQL: Item ignored
ORA-06550: line 15, column 38:
PLS-00320: the declaration of the type of this expression is incomplete or malformed
ORA-06550: line 15, column 4:
PL/SQL: SQL Statement ignored
ORA-06550: line 17, column 25:
PLS-00320: the declaration of the type of this expression is incomplete or malformed
ORA-06550: line 17, column 4:
PL/SQL: Statement ignored
What i´m doing wrong??
--Sorry but i´m newby in Pl-SQL