Re: alter + preserving dependencies - Mailing list pgsql-hackers

From Dimitri Fontaine
Subject Re: alter + preserving dependencies
Date
Msg-id 1A1CA5D7-C727-41BB-A5D6-8D143E18ACE3@hi-media.com
Whole thread Raw
In response to Re: alter + preserving dependencies  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: alter + preserving dependencies
List pgsql-hackers
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

Le 6 mai 08 à 19:44, Tom Lane a écrit :

> Andrew Dunstan <andrew@dunslane.net> writes:
>> Josh Berkus wrote:
>>> I don't follow you.  I can currently add a column, without breaking
>>> either foriegn keys or inheritance.  What's the problem?
>
>> not for a view at least.
>
> Yeah, the restrictions on replacing a view definition date from before
> we had any fancy ALTER TABLE stuff.  They could probably use a re-
> visit.

Could we add some other VIEWs features while revisiting?
We had some question on #postgresqlfr about updatable views and the
rewrite rule system, which I could chat about with Jan Wieck on
#postgresql too. The problem we had was related to DEFAULT versus NULL
handling from an insert or update RULE and how to avoid having an
absent column rewritten as NULL instead of DEFAULT.

Could we consider ALTER VIEW ALTER COLUMN ... SET DEFAULT ...;?

Bonus question: why is the rewriter unable to distinguish whether NULL
comes from the user or comes from the column was not part of the user
query?

Regards,
- --
dim
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Darwin)

iEYEARECAAYFAkghQRIACgkQlBXRlnbh1bnWAQCeNF4RJwWLcGmmPPE8eUGn3/Yi
6NEAn1YOQ3Bz7L+tD01rQqqeyNt7djwA
=MXD8
-----END PGP SIGNATURE-----


pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: Re: [PATCHES] a tsearch2 (8.2.4) dictionary that only filters out stopwords
Next
From: KaiGai Kohei
Date:
Subject: Re: [0/4] Proposal of SE-PostgreSQL patches