X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (neptune.hub.org [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id B0A77D1EA28 for ; Wed, 21 Jan 2004 19:05:39 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 15225-01 for ; Wed, 21 Jan 2004 15:05:09 -0400 (AST) Received: from joeconway.com (66-146-172-86.skyriver.net [66.146.172.86]) by svr1.postgresql.org (Postfix) with ESMTP id A9539D1EBC0 for ; Wed, 21 Jan 2004 14:38:18 -0400 (AST) Received: from [206.19.64.3] (account jconway HELO joeconway.com) by joeconway.com (CommuniGate Pro SMTP 4.1.8) with ESMTP-TLS id 781143; Wed, 21 Jan 2004 10:35:22 -0800 Message-ID: <400EC6A2.20007@joeconway.com> Date: Wed, 21 Jan 2004 10:36:18 -0800 From: Joe Conway User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.5) Gecko/20031007 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Tom Lane Cc: Rajesh Kumar Mallah , pgsql-sql@postgresql.org Subject: Re: array_lower /array_prepend doubt References: <400E85EC.4000106@trade-india.com> <1648.1074705270@sss.pgh.pa.us> <400EBEF0.6060005@joeconway.com> <2597.1074708698@sss.pgh.pa.us> In-Reply-To: <2597.1074708698@sss.pgh.pa.us> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200401/200 X-Sequence-Number: 16593 Tom Lane wrote: > The other point about pg_dump failing to correctly restore arrays with > nondefault lower bounds is a good one, though. We need to think about > how to fix that. I'll put some thought into it, but note that it is hardly a new issue -- it's been possible to create an array with < 1 lower bound since well before 7.4: regression=# select version(); version ----------------------------------------------------------------------- PostgreSQL 7.3.5 on i686-pc-linux-gnu, compiled by GCC gcc (GCC) 3.2.2 20030222 (Red Hat Linux 3.2.2-5) (1 row) regression=# create table a(f1 int, f2 int[]); CREATE TABLE regression=# insert into a values (1,'{1,2}'); INSERT 565511 1 regression=# update a set f2[0] = 0 where f1 = 1; UPDATE 1 regression=# select array_dims(f2) from a; array_dims ------------ [0:2] (1 row) Joe