Re: Some questions about the array. - Mailing list pgsql-hackers

From Pavel Stehule
Subject Re: Some questions about the array.
Date
Msg-id CAFj8pRB3J5JbFKLwK31e2axsR1iAhXXQEM8y0TqCr=U2oEb0hw@mail.gmail.com
Whole thread Raw
In response to Re: Some questions about the array.  (YUriy Zhuravlev <u.zhuravlev@postgrespro.ru>)
Responses Re: Some questions about the array.  (YUriy Zhuravlev <u.zhuravlev@postgrespro.ru>)
List pgsql-hackers


2015-11-09 13:07 GMT+01:00 YUriy Zhuravlev <u.zhuravlev@postgrespro.ru>:
On Monday 09 November 2015 12:48:54 you wrote:
> I am sorry - it is looking pretty obscure. Really need this feature?

IMHO yes.
Now for write: array[~2:~-2] you need like:
array[array_lower(array, 1)+3: array_upper(array, 1)-2]

Worse when long names. Besides the extra functions calls.

It is ugly, but you can wrap it to function - so still I don't see any reason, why it is necessary

Regards

Pavel

 

Thanks.
--
YUriy Zhuravlev
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company


--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

pgsql-hackers by date:

Previous
From: Marc Mamin
Date:
Subject: Re: Some questions about the array.
Next
From: Vitaly Burovoy
Date:
Subject: Re: Some questions about the array.