sql - For Loop With Object Table? -


say object functions etc. defined on , have table

create table person_obj_table of person_typ;

now want use loop iterate through table so

  x in (select value(t) person_obj_table t lastname = 'smith') loop     dbms_output.put_line(x.get_fullname);   end loop; 

this seems fail though x not recognized person_typ. clue here?

give value(x) expression name v, , use name:

for x in (select value(t) v person_obj_table t lastname = 'smith') loop   dbms_output.put_line(x.v.get_fullname); end loop; 

Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -