Re: [BUGS] General Bug Report: alter table tabname rename to newname does not rename extra files

From: Bruce Momjian <maillist(at)candle(dot)pha(dot)pa(dot)us>
To: Jim Mercer <jim(at)reptiles(dot)org>
Cc: pgsql-bugs(at)postgreSQL(dot)org
Subject: Re: [BUGS] General Bug Report: alter table tabname rename to newname does not rename extra files
Date: 1999-05-10 16:38:30
Message-ID: 199905101638.MAA07560@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Added to TODO list.

>
> ============================================================================
> POSTGRESQL BUG REPORT TEMPLATE
> ============================================================================
>
>
> Your name : Jim Mercer
> Your email address : jim(at)reptiles(dot)org
>
> Category : runtime: back-end
> Severity : critical
>
> Summary: alter table tabname rename to newname does not rename extra files
>
> System Configuration
> --------------------
> Operating System : FreeBSD 2.x/3.x
>
> PostgreSQL version : 6.4 and 6.4.2
>
> Compiler used : gcc
>
> Hardware:
> ---------
> Pentium 128M ram
> FreeBSD bigbird.nag.ca 3.0-RELEASE FreeBSD 3.0-RELEASE #1: Tue Feb 2 22:50:41 EST 1999 root(at)bigbird(dot)nag(dot)ca:/usr/src/sys/compile/BIGBIRD i386
>
>
> Versions of other tools:
> ------------------------
>
>
> --------------------------------------------------------------------------
>
> Problem Description:
> --------------------
> when a table exceeds 2gb, it appears that postgres will create subfiles for the data.
> when you rename a table, the sub files do no get renamed.
> see backend/commands/rename.c [renamerel()]
>
> --------------------------------------------------------------------------
>
> Test Case:
> ----------
> create a table in excess of 2gig, which in turn creates subfiles
> in data/base/tabname.
> rename the table.
> the subfiles are not renamed.
>
>
> --------------------------------------------------------------------------
>
> Solution:
> ---------
> possible solution is to check if the table has subfiles, look for those subfiles and rename them as well.
>
>
> --------------------------------------------------------------------------
>
>
>

--
Bruce Momjian | http://www.op.net/~candle
maillist(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Bruce Momjian 1999-05-10 16:59:11 Re: [BUGS] General Bug Report: pg_dump sets quotes wrong when dumping groups-acls.
Previous Message Bruce Momjian 1999-05-10 16:29:28 Re: [BUGS] General Bug Report: obscure error when misusing table name as an attribute