Re: BUG #14294: Problem in generate series between dates

From: Dean Rasheed <dean(dot)a(dot)rasheed(at)gmail(dot)com>
To: Andrew Gierth <andrew(at)tao11(dot)riddles(dot)org(dot)uk>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Christoph Berg <myon(at)debian(dot)org>, pablopumarino(at)gmail(dot)com, "pgsql-bugs(at)postgresql(dot)org" <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: BUG #14294: Problem in generate series between dates
Date: 2016-08-31 23:05:04
Message-ID: CAEZATCXeYX74QxFJD=5HMfHcZGLO+eL_MfyFs24QZbNyLLWjYg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On 31 August 2016 at 23:07, Andrew Gierth <andrew(at)tao11(dot)riddles(dot)org(dot)uk> wrote:
> Some experimentation with creating
> pg_catalog.generate_series(date,date,integer) and trying the usual
> use-cases doesn't seem to turn up any issues. Looking at the list of
> implicit casts also doesn't suggest that there would be any problems.
>

Adding generate_series(date,date,integer) was attempted a recently
[1], but led to some ambiguities that broke some queries that
currently work. At the time the new function was presented merely as a
convenience to save having to cast results, but I think this
discussion adds more weight to the argument for such a function.
Perhaps adding generate_series(date,date,interval) might work.

[1] https://www.postgresql.org/message-id/flat/56EAB874.9040205%40pgmasters.net

Regards,
Dean

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Dean Rasheed 2016-08-31 23:36:25 Re: BUG #14294: Problem in generate series between dates
Previous Message Andrew Gierth 2016-08-31 22:07:50 Re: BUG #14294: Problem in generate series between dates