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

From Merlin Moncure
Subject Re: Some questions about the array.
Date
Msg-id CAHyXU0zNHQ1m+E=+T-AJAZsb3PDFqF22tjz6FtD_FZULq1rFuA@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
On Mon, Nov 30, 2015 at 3:05 PM, YUriy Zhuravlev
<u.zhuravlev@postgrespro.ru> wrote:
> On Monday 30 November 2015 08:58:49 you wrote:
>> +1  IMO this line of thinking is a dead end.  Better handled via
>> functions, not syntax
>
> Maybe then add array_pyslice(start, end) when start is 0 and with negative
> indexes? Only for 1D array.
> What do you think?

TBH, I'm not really thrilled about the concept in general; it (zero
based indexing support) doesn't meet the standard of necessity for
adding to the core API and as stated it's much to magical.  If it was
me, I'd be making a pgxn extension for zero based arrays that are zero
based;  it could be 100% SQL wrappers so I'd be pretty easy to install
for interested parties.

merlin



pgsql-hackers by date:

Previous
From: Alexander Korotkov
Date:
Subject: Re: Use pg_rewind when target timeline was switched
Next
From: YUriy Zhuravlev
Date:
Subject: Re: Some questions about the array.