| From: | Shin Berg <sjh910805(at)gmail(dot)com> |
|---|---|
| To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Cc: | Amit Khandekar <amitdkhan(dot)pg(at)gmail(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org |
| Subject: | Re: Inconsistency in owner assignment between INDEX and STATISTICS |
| Date: | 2026-03-16 01:15:24 |
| Message-ID: | CACSdjfN6ydot=nibVF5__-Q7H7AFUG5r96EYbV9SWnM4VBmVyg@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Thank you for the additional context, Tom. That makes the design intent
much clearer.
Cross-table statistics, if realized, would be a significant improvement for
join cardinality estimation; looking forward to seeing that develop.
Regards,
Joshua Shin
On Mon, Mar 16, 2026 at 5:09 AM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Shin Berg <sjh910805(at)gmail(dot)com> writes:
> > Thank you for the detailed feedback, Amit.
> > You're right on both points. I had been comparing STATISTICS against
> INDEX
> > and treating the difference as an inconsistency, but as you point out,
> > INDEX ownership is special — it's tied to the table and intentionally not
> > user-adjustable. STATISTICS follows the same ownership model as VIEW (the
> > creator becomes the owner), which is consistent and by design.
>
> One point that was not mentioned is that while indexes are necessarily
> tied to a single table, statistics objects might not always be. The
> long-term hope is to allow statistics on cross-table combinations of
> columns, which is why the syntax was intentionally set up to look like
> SELECT. So, just like views, it's reasonable to give them independent
> ownership.
>
> regards, tom lane
>
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Peter Smith | 2026-03-16 01:21:00 | Re: DOCS - Server Applications [option] should be [option...] |
| Previous Message | Michael Paquier | 2026-03-16 01:08:22 | Re: pgcrypto/des tests fail on riscv64 due to clang's code generation anomaly |