From: | Philip Warner <pjw(at)rhyme(dot)com(dot)au> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Details for planned template0/template1 change |
Date: | 2000-11-15 04:59:38 |
Message-ID: | 3.0.5.32.20001115155938.03562950@mail.rhyme.com.au |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
At 23:48 14/11/00 -0500, Tom Lane wrote:
>Philip Warner <pjw(at)rhyme(dot)com(dot)au> writes:
>>> Given the present backend coding, all the DBs in an installation will
>>> have the same lastsysoid as template0 anyway, barring manual
>>> intervention.
>
>> Not the way the current 'CREATE DATABASE' code works - remember the changes
>> to set the OID at create time? AFAICT, that's still there.
>
>Look again. lastsysoid is now inherited from the database being cloned.
It looks to me like that was the intent of the code; but there is still:
tuple = heap_formtuple(pg_database_dsc, new_record, new_record_nulls);
tuple->t_data->t_oid = dboid; /* override heap_insert's OID
selection */
heap_insert(pg_database_rel, tuple);
which I think stuffs up everything, since dboid was allocated earlier in
the same call. But I agree, the code looks like it tries to do what you said.
I could have missed something, though.
>AFAICT all your subsequent comments are based on that
>misunderstanding...
Pretty much. Sorry. Is there a smiley for embarrasment?
----------------------------------------------------------------
Philip Warner | __---_____
Albatross Consulting Pty. Ltd. |----/ - \
(A.B.N. 75 008 659 498) | /(@) ______---_
Tel: (+61) 0500 83 82 81 | _________ \
Fax: (+61) 0500 83 82 82 | ___________ |
Http://www.rhyme.com.au | / \|
| --________--
PGP key available upon request, | /
and from pgp5.ai.mit.edu:11371 |/
From | Date | Subject | |
---|---|---|---|
Next Message | Philip Warner | 2000-11-15 05:03:05 | Re: Details for planned template0/template1 change |
Previous Message | Tom Lane | 2000-11-15 04:48:34 | Re: Details for planned template0/template1 change |