I have to generate a list with two columns of day intervals for every month in a specific period. First column must be the first day of month and the second column the last
Based on this answer:
select d::date as start_date,(d + '1 month'::interval - '1 day'::interval )::date end_date from generate_series('2014-01-01'::date, '2014-06-30'::date, '1 month'::interval) d