Re: Expr. extended stats are skipped with equality operator - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Expr. extended stats are skipped with equality operator
Date
Msg-id 2330.1659722898@sss.pgh.pa.us
Whole thread Raw
In response to Re: Expr. extended stats are skipped with equality operator  (Justin Pryzby <pryzby@telsasoft.com>)
List pgsql-hackers
Justin Pryzby <pryzby@telsasoft.com> writes:
> A reproducer for this:

> CREATE TABLE t1(x int[], y float);
> INSERT INTO t1 SELECT array[1], a FROM generate_series(1,99)a;
> CREATE STATISTICS s2 ON (CASE x[1] WHEN 1 THEN true ELSE false END), y FROM t1;
> ANALYZE t1;

> explain analyze SELECT * FROM t1 WHERE CASE x[1] WHEN 1 THEN true ELSE false END AND y=1;
> ERROR:  unknown clause type: 134

Sigh ... this is just horrid.  I think I see what to do about it though,
and since Tomas seems to have been AWOL for awhile now, I don't think
we'll get a fix by Monday if we wait for him.  I'll take a shot at
fixing it; it seems unlikely that I can make it worse.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Robert Treat
Date:
Subject: Re: [doc] fix a potential grammer mistake
Next
From: Stephen Frost
Date:
Subject: Re: Proposal: Support custom authentication methods using hooks