Insert/select union bug

From: Peter <peter(at)greatnowhere(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Insert/select union bug
Date: 2006-09-27 09:14:44
Message-ID: 451A4104.7070800@greatnowhere.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

create table temp(a timestamptz);

insert into temp(a) select NULL; /* this passes */

insert into temp(a) select NULL union select NULL; /* fails:
ERROR: column "a" is of type timestamp with time zone but expression is
of type text
*/

I need to insert hundreds of thousands of rows, and insert into ...
select union is by far more efficient than multitude of inserts.

Postgres 8.1.3, FreeBSD.

Has this (maybe) been fixed in most recent release?

Peter

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Martijn van Oosterhout 2006-09-27 09:57:54 Re: Insert/select union bug
Previous Message Jim Nasby 2006-09-27 05:49:22 Re: Replication and PITR