On 1/22/21 5:01 AM, Justin Pryzby wrote:
> > In any case, why are there so many parentheses ?

On Fri, Jan 22, 2021 at 02:09:04PM +0100, Tomas Vondra wrote:
> That's a bug in pg_get_statisticsobj_worker, probably. It shouldn't be
> adding extra parentheses, on top of what deparse_expression_pretty does.
> Will fix.

The extra parens are still here - is it intended ?

postgres=# CREATE STATISTICS s ON i, (1+i), (2+i) FROM t;
CREATE STATISTICS
postgres=# \d t
                 Table "public.t"
 Column |  Type   | Collation | Nullable | Default 
--------+---------+-----------+----------+---------
 i      | integer |           |          | 
Statistics objects:
    "public"."s" ON i, ((1 + i)), ((2 + i)) FROM t

-- 
Justin


Reply via email to