Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!
There may be other errors in the code - haven't really checked, but you should get my point. Can I extract column data and number of columns and eventually column names in a way something like above?
declare cursor c_pr is select * from a_table; r_pr c_pr%ROWTYPE; begin open c_pr loop fetch c_pr into r_pr; exit when c_pr%NOTFOUND; for i in 1..r_pr.number_of_columns loop DBMS_OUPUT.put(r_pr.column(i)||chr(9)); end loop; DBMS_OUTPUT.put_line(''); end loop; close c_pr; end