Re: Combining array slicing and indexing causes incorrect/confusing results - Mailing list pgsql-bugs

From Tom Lane
Subject Re: Combining array slicing and indexing causes incorrect/confusing results
Date
Msg-id 3356242.1737479096@sss.pgh.pa.us
Whole thread Raw
In response to Combining array slicing and indexing causes incorrect/confusing results  (Jelte Fennema-Nio <me@jeltef.nl>)
List pgsql-bugs
Jelte Fennema-Nio <me@jeltef.nl> writes:
> Due to the way SubscriptingRef works there's no way for it to describe
> a subscript sequence that both does a slice and a regular index in the
> same SubscriptingRef.

Well, yeah, because they're fundamentally different operations.
A slice produces a value of the array type, a regular index
operation produces a value of the element type.  So if you
mix the notations we assume you really meant slicing in each
subscript.

            regards, tom lane



pgsql-bugs by date:

Previous
From: Jelte Fennema-Nio
Date:
Subject: Combining array slicing and indexing causes incorrect/confusing results
Next
From: Chris BSomething
Date:
Subject: Re: BUG #18594: CASE WHEN ELSE failing to return the expected output when the same colum is used in WHEN and ELSE