Re: An Idea for OID conflicts - Mailing list pgsql-hackers

From Tom Lane
Subject Re: An Idea for OID conflicts
Date
Msg-id 18881.1158620849@sss.pgh.pa.us
Whole thread Raw
In response to Re: An Idea for OID conflicts  (Tom Dunstan <pgsql@tomd.cc>)
Responses Re: An Idea for OID conflicts  (Tom Dunstan <pgsql@tomd.cc>)
List pgsql-hackers
Tom Dunstan <pgsql@tomd.cc> writes:
> [ some good arguments snipped ]

> I like the script idea much better. It wouldn't be bad to even allow
> patches to be submitted with OIDs in the high 9000 or whatever range.
> The committer responsible for committing the patch could just run the
> update script before comitting the code.

The scary thing about a script is the assumption that it will make all
and only the changes needed.  Four-digit magic numbers are not that
uncommon in C code.  I think it might be safer if we made the arbitrary
OID range for an uncommitted patch be large, say eight digits (maybe
"12345xxx").  The script would knock these down to 4-digit numbers,
ie removing one tab stop, so it wouldn't be too hard on your formatting.
Given the current OID generation mechanism, the presence of large OIDs
in the initial catalogs shouldn't be a problem for testing patches,
even assuming that the OID counter gets that high in your test database.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: minor feature request: Secure defaults during
Next
From: Tom Dunstan
Date:
Subject: Re: An Idea for OID conflicts