I need to write a report that generates summary totals against a table with date ranges for each record.
table data: option start_date end_date opt1
declare v_curr_date date; for i in to_number(to_char(p_date_from ,'j')) .. to_number(to_char(p_date_to ,'j')) loop v_curr_date = to_date(to_char(i),'j'); --make any operation on v_curr_date (like insert into table) end loop; end;