Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 5B42A1337B8C for ; Thu, 11 Nov 2010 11:48:18 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 65661-08 for ; Thu, 11 Nov 2010 15:48:11 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by mail.postgresql.org (Postfix) with ESMTP id E4E8A1337B5A for ; Thu, 11 Nov 2010 11:48:10 -0400 (AST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id oABFmAvf015299; Thu, 11 Nov 2010 10:48:10 -0500 (EST) To: "Yeb Havinga" cc: pgsql-bugs@postgresql.org Subject: Re: BUG #5748: Invalid oidvector data during binary recv In-reply-to: <201011111430.oABEUVPe067398@wwwmaster.postgresql.org> References: <201011111430.oABEUVPe067398@wwwmaster.postgresql.org> Comments: In-reply-to "Yeb Havinga" message dated "Thu, 11 Nov 2010 14:30:31 +0000" Date: Thu, 11 Nov 2010 10:48:10 -0500 Message-ID: <15298.1289490490@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-5 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201011/68 X-Sequence-Number: 28648 "Yeb Havinga" writes: > postgres=# create table a as select ''::oidvector; > SELECT 1 > postgres=# copy a to '/tmp/test' with binary; > COPY 1 > postgres=# copy a from '/tmp/test' with binary; > ERROR: invalid oidvector data The problem seems to be that array_recv passes back a zero-dimensional array, *not* a 1-D array, when it observes that the input has no elements. A zero-D array is not part of the subset of possible arrays that we allow for oidvector. I'm less than convinced that this is worth fixing. oidvector is not intended for general-purpose use anyway. What's the use-case where this would come up? regards, tom lane