ORA-06530

Error: ORA-06530: Reference to uninitialized composite

Causa: An object, LOB, or other composite was referenced as a left hand side without having been initialized.

Acción: Initialize the composite with an appropriate constructor or whole-object assignment.

COMENTARIOS:

por jacagudelo | 14/03/2012 17:57:14

RE: ORA-06530

In trying to fill a variable type, you must initialize depending on the manner of filling:
if using the clause ".extend" is initialized
/ / ---------------------------------
declare
r emple_type_tb;
begin;
r: = emple_type_tb ();
r.extend;
r (r.count): = emple_type (1, 'one', 2.3);
return r;
end;
/ / --------------------------------
if you use the function "pipelined" and initializes
/ / --------------------------------
declare
emple_type r: = emple_type (NULL, NULL, NULL, NULL);
begin
FOR i IN 1 .. 2 LOOP
IF (i = 1) THEN
r.codigo: = 1;
r.nom: = 'one';
r.salario: = 2;
r.comision: = 3;
END IF;

and to see the result we use the cast
select * from table (function ());

good luck!!!!!

por David Sánchez | 11/04/2012 09:11:18

RE: ORA-06530

Thanks jacagudelo!

por Abimael | 01/03/2019 19:04:07

RE: ORA-06530

Thank you very much jacagudelo!

Great comment!