StatisticsObjIsVisibleExt lacks "do not look in temp namespace"

From: Noah Misch <noah(at)leadboat(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: StatisticsObjIsVisibleExt lacks "do not look in temp namespace"
Date: 2025-09-20 16:21:16
Message-ID: 20250920162116.2e.nmisch@google.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

StatisticsObjIsVisibleExt() lacks the "do not look in temp namespace" code of
the rest of the non-relation, non-type namespace searches. Patch attached.
See its log messages for the consequences.

Incidentally, stats on temp tables do default to a permanent schema. That
seems fine, though:

set search_path = public;
CREATE TEMP TABLE ab1 (a INTEGER, b INTEGER, c INTEGER);
CREATE STATISTICS s ON a, b FROM ab1; -- creates public.s
\dX *.*

Attachment Content-Type Size
stats-ext-visible-v1.patch text/plain 3.4 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2025-09-20 21:21:19 Re: allow benign typedef redefinitions (C11)
Previous Message Alvaro Herrera 2025-09-20 15:20:48 Re: AIX support