agora inbox for postgres@postgres.berkeley.edu  
help / color / mirror / Atom feed
From: aoki@postgres.berkeley.edu
To: postgres@postgres.berkeley.edu
Subject: Re: < ``arrays of arrays'' >
Date: Tue, 19 Jan 93 14:05:07 PST
Message-ID: <9301192207.AA22927@postgres.Berkeley.EDU> (raw)
In-Reply-To: <9301191958.AA21929@postgres.Berkeley.EDU>

> is the following behavior concerning the entry 'Susi' correct ?
> append bla (name="Susi", telno = "{ "1191" }"      ) \g
> ---------------------------------------------
> | Susi        | {}            | (null)      |
> ---------------------------------------------

No.  This is a bug in the array code.  The code that parses array strings
first counts values in such a way that it can never count exactly one value.
Hence, you can never have an array constant with exactly one value.

This has been fixed in 4.1 (which will be out Any Day Now).  However, you
*have* to quote a single value (or the parser can't tell the difference
between a blank text string and a null array).  An artifact of the syntax..
--
  Paul M. Aoki  |  CS Div., Dept. of EECS, UCB  |  aoki@postgres.Berkeley.EDU
                |  Berkeley, CA 94720           |  ...!uunet!ucbvax!aoki



reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: postgres@postgres.berkeley.edu
  Cc: aoki@postgres.berkeley.edu
  Subject: Re: < ``arrays of arrays'' >
  In-Reply-To: <9301192207.AA22927@postgres.Berkeley.EDU>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox