Re: Operator is not unique

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
Cc: PegoraroF10 <marcos(at)f10(dot)com(dot)br>, pgsql-general(at)postgresql(dot)org
Subject: Re: Operator is not unique
Date: 2019-09-30 14:54:15
Message-ID: 26283.1569855255@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com> writes:
> The list of extensions that you sent earlier are fairly common. I would
> not expect them to be contributing to the below otherwise there would
> have been more reports of what you are seeing.

A quick "grep" shows that there is nothing named "day_inc" in core
Postgres nor any of the contrib extensions. So this is something
homegrown. It looks to me like somebody wanted a plus operator
that would add numerics and dates/timestamps/timestamptzs, and
figured they could be lazy and make one operator using "anyelement".
But this will capture numeric plus *anything*, so it was not a
good idea. I'd recommend dropping the use of anyelement and just
making three non-polymorphic operators.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Marco Ippolito 2019-09-30 16:01:17 Re: "Failed to connect to Postgres database"
Previous Message Adrian Klaver 2019-09-30 14:39:33 Re: Operator is not unique