Re: [HACKERS] Re: [GENERAL] drop/rename table and transactions

From: Vadim Mikheev <vadim(at)krs(dot)ru>
To: Mike Mascari <mascarm(at)mascari(dot)com>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, Lamar Owen <lamar(dot)owen(at)wgcr(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Lincoln Yeoh <lylyeoh(at)mecomb(dot)com>, pgsql-general(at)postgreSQL(dot)org, PostgreSQL Developers List <hackers(at)postgreSQL(dot)org>
Subject: Re: [HACKERS] Re: [GENERAL] drop/rename table and transactions
Date: 1999-11-29 06:29:06
Message-ID: 38421D32.90A2E2CB@krs.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers

Mike Mascari wrote:
>
> Will that aid in fixing a problem such as this:
>
> session 1:
>
> CREATE TABLE example1(value int4);
> BEGIN;
>
> session 2:
>
> BEGIN;
> ALTER TABLE example1 RENAME TO example2;
>
> session 1:
>
> INSERT INTO example1 VALUES (1);
> END;
> NOTICE: Abort Transaction and not in in-progress state
> ERROR: Cannot write block 0 of example1 [test] blind
>
> session 2:
>
> END;
> NOTICE: Abort Transaction and not in in-progress state
> ERROR: Cannot write block 0 of example1 [test] blind

Seems that oid file names will fix this...
Currently, each shared buffer description structure has
database/table names for the purposes of "blind" writes
(when backend cache hasn't entry for relation and so
bufmgr can't use cache to get names from oids).
ALTER TABLE ... RENAME renames relation file(s) but doesn't
change relation name inside shbuffers...

> Mike (implicit commit) Mascari

-:)))

Vadim

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Ken Gunderson 1999-11-29 06:32:55 Re: [GENERAL] memory
Previous Message Mike Mascari 1999-11-29 06:16:45 Re: [HACKERS] Re: [GENERAL] drop/rename table and transactions

Browse pgsql-hackers by date

  From Date Subject
Next Message Ed Loehr 1999-11-29 06:45:17 Re: [HACKERS] How to get OID from INSERT in PL/PGSQL?
Previous Message Mike Mascari 1999-11-29 06:16:45 Re: [HACKERS] Re: [GENERAL] drop/rename table and transactions