Re: preserving statistics settings

From: nconway(at)klamath(dot)dyndns(dot)org (Neil Conway)
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: preserving statistics settings
Date: 2002-07-19 16:51:43
Message-ID: 20020719165143.GA22115@klamath.dyndns.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jul 19, 2002 at 12:39:16PM -0400, Tom Lane wrote:
> nconway(at)klamath(dot)dyndns(dot)org (Neil Conway) writes:
> > Shouldn't the effect of ALTER TABLE ALTER COLUMN SET STATISTICS be
> > recorded by pg_dump?

> One problem is that I didn't really want to enshrine the current
> default value in a bunch of pg_dump scripts, in case we decide it's
> too small.

Good point.

> If there were a reliable way to tell whether the attstattarget value had
> actually been set by the user, or was merely a default, it'd be easier
> to determine what pg_dump should do.

Hmmm... we could allow SET STATISTICS to take 'DEFAULT' easily enough
(and that might even be a good idea in any case), but you're right --
without a way for pg_dump to determine the default value and/or whether
the admin have explicitely changed the attstattarget for that column,
there's not much that can be done...

I suppose we could hard-code the current default value into pg_dump,
but that's pretty ugly.

Does anyone have a better suggestion?

Cheers,

Neil

--
Neil Conway <neilconway(at)rogers(dot)com>
PGP Key ID: DB3C29FC

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Barry Lind 2002-07-19 17:03:04 Re: heap_delete, heap_mark4update must reset t_ctid
Previous Message Tom Lane 2002-07-19 16:39:16 Re: preserving statistics settings