From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Konstantin Knizhnik <k(dot)knizhnik(at)postgrespro(dot)ru> |
Cc: | PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Two questions about Postgres parser |
Date: | 2017-02-27 16:37:23 |
Message-ID: | 10429.1488213443@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Konstantin Knizhnik <k(dot)knizhnik(at)postgrespro(dot)ru> writes:
> 1. Moving-aggregate implementation should return the same type as plain
> implementation. Yes, in most cases it is hard to find arguments why them
> should return different types. But it is not true for vectorized
> operations...
I can't see a reason why we would want to go there. And if your design
for vectorized operations requires different user-visible semantics than
for the same operation non-vectorized, don't you have a problem anyway?
> 2. Implicit user defined type casts are not applied for COALESCE operator:
That has nothing to do with whether the cast is user-defined. It has to
do with not wanting to automatically unify types across type-category
boundaries (in this case, numeric vs. composite categories). That's per
step 4 here:
https://www.postgresql.org/docs/devel/static/typeconv-union-case.html
and it's not an easy thing to get rid of because if you're considering
more than one type category then the heuristic about preferring "preferred
types" breaks down --- how do you know which category's preferred type to
prefer?
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Andres Freund | 2017-02-27 16:48:28 | Re: PATCH: two slab-like memory allocators |
Previous Message | Andres Freund | 2017-02-27 16:36:17 | Re: [HACKERS] PGSERVICEFILE as a connection string parameter |