Bug Report - alter table does not work on temporary tables

From: Clark Evans <clark(dot)evans(at)manhattanproject(dot)com>
To: pgsql-hackers(at)postgreSQL(dot)org
Subject: Bug Report - alter table does not work on temporary tables
Date: 1999-03-31 16:22:40
Message-ID: 37024BD0.D3411D48@manhattanproject.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

============================================================================
POSTGRESQL BUG REPORT TEMPLATE
============================================================================

Your name : Clark Evans
Your email address : clark(dot)evans(at)manhattanproject(dot)com

System Configuration
---------------------
Architecture (example: Intel Pentium) : Pentium

Operating System (example: Linux 2.0.26 ELF) : Linux RH 5.2

PostgreSQL version (example: PostgreSQL-6.4) : Current CVS version

Compiler used (example: gcc 2.8.0) :

Please enter a FULL description of your problem:
------------------------------------------------

Alter table does not seem to operate on tempoary tables
and does not throw an error. I would like to be able
to add columns to temp tables to do a cross-tab query.

Please describe a way to repeat the problem. Please try to provide a
concise reproducible example, if at all possible:
----------------------------------------------------------------------

clark=> create temp table x ( x text );
CREATE
clark=> insert into x values ( 'x' );
INSERT 270675 1
clark=> select * from x;
x
-
x
(1 row)

clark=> alter table x add column y text;
ADD
clark=> select * from x;
x
-
x
(1 row)

clark=> insert into x values ('a','b');
ERROR: INSERT has more expressions than target columns.

If you know how this problem might be fixed, list the solution below:
---------------------------------------------------------------------

The only work-around I know is to use arrays. I'm trying that.

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 1999-03-31 16:30:17 Re: [HACKERS] Removing derived files from CVS
Previous Message Thomas Lockhart 1999-03-31 16:21:35 Re: [HACKERS] Date operations