declare
  enum o_employees.eno%type;
  phs o_employees.person.phones%type;
begin
  enum := 1002;
  select e.person.phones into phs from o_employees e where e.eno = enum;
  for i in 1..3 loop
    if (phs(i) is not null) then
      dbms_output.put_line('Phone for employee ' || 
                           enum   || ' is ' || phs(i));
    end if;
  end loop;
end;
/
show errors
