Home > database > This date dimension table, how to use the stored procedure loop inserts, date up to 2030
This date dimension table, how to use the stored procedure loop inserts, date up to 2030
Time:09-27
CodePudding user response:
Is there a man, for help
CodePudding user response:
Select the date '2016-06-29' + ddate rownum - 1, Trunc (trunc (the date '2016-06-29' rownum + 1), 'mm) monstart, Trunc (last_day (the date '2016-06-29') + rownum - 1) monend The from dual Connect by rownum & lt; The date '2030-12-31' - the date '2016-06-29' + 1;