declare
type NedMcDodd_aa is table of NedMcDodd%rowtype index by binary_integer;
cursor c_NedMcDodd
is
select n.id
, n.firstname
, n.lastname
, n.type
from NedMcDodd n
where n.type in (12, 15, 18);
l_NedMcDodds NedMcDodd_aa;
begin
open c_NedMcDodd;
fetch c_NedMcDodd bulk collect into l_NedMcDodds;
close c_NedMcDodd;
dbms_output.put_line('Number of relatives :'||l_NedMcDodds.count);
for indx in l_NedMcDodds.first .. l_NedMcDodds.last loop
dbms_output.put_line('Relative('||l_NedMcDodds(indx).id||') : '||l_NedMcDodds(indx).firstname);
end loop;
end;