From: Tom Lane <tgl@sss.pgh.pa.us>
To: jian he <jian.universality@gmail.com>
Cc: pgsql-general list <pgsql-general@lists.postgresql.org>
Subject: Re: confused by int2vector typdelim
Date: Wed, 24 May 2023 10:09:58 -0400
Message-ID: <1125496.1684937398@sss.pgh.pa.us> (raw)
In-Reply-To: <CACJufxFViGB-Y=fVRgb7mb8DJe4Oy09uxzVACpp18-AcM2zsSQ@mail.gmail.com>
References: <CACJufxFViGB-Y=fVRgb7mb8DJe4Oy09uxzVACpp18-AcM2zsSQ@mail.gmail.com>
jian he <jian.universality@gmail.com> writes:
> should I expect the typdelim be a white space? Since '1 2'::int2vector
> works, '1,2'::int2vector does not work.
typdelim applies to the type's associated array type, that is
int2vector[].
regression=# select '{1 2,3 4 5}'::int2vector[];
int2vector
-----------------
{"1 2","3 4 5"}
(1 row)
regards, tom lane
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: tgl@sss.pgh.pa.us, jian.universality@gmail.com
Subject: Re: confused by int2vector typdelim
In-Reply-To: <1125496.1684937398@sss.pgh.pa.us>
References: <CACJufxFViGB-Y=fVRgb7mb8DJe4Oy09uxzVACpp18-AcM2zsSQ@mail.gmail.com> <1125496.1684937398@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox