Re: Multivariate statistics and expression indexes

Tomas Vondra <tomas.vondra@2ndquadrant.com>

From: Tomas Vondra <tomas.vondra@2ndquadrant.com>
To: Bruce Momjian <bruce@momjian.us>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2017-02-21T00:27:53Z
Lists: pgsql-hackers
On 02/21/2017 12:13 AM, Bruce Momjian wrote:
> At the risk of asking a stupid question, we already have optimizer
> statistics on expression indexes.  In what sense are we using this for
> multi-variate statistics, and in what sense can't we.
>

We're not using that at all, because those are really orthogonal 
features. Even with expression indexes, the statistics are per 
attribute, and the attributes are treated as independent.

There was a proposal to also allow creating statistics on expressions 
(without having to create an index), but that's not supported yet.

regards

-- 
Tomas Vondra                  http://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


Commits

  1. Collect and use multi-column dependency stats

  2. Implement SortSupport for macaddr data type

  3. Implement multivariate n-distinct coefficients

  4. Generate fmgr prototypes automatically