Josh Berkus <j...@agliodbs.com> writes: > ... and if arr1, 2 and 3 are exactly the same length, this creates a > coordinated dataset. I can even use the unnest_ordinality() extension > function to get the ordinality of this combined dataset:
> SELECT id, > (unnest_ordinality(arr1)).element_number as array_index, > unnest(arr1) as arr1, > unnest(arr2) as arr2, > unnest(arr3) as arr3 > FROM lotsarrays; > There are reasons why this will be complicated to implement WITH > ORDINALITY; DF, Andrew and I discussed them on IRC. So allowing WITH > ORDINALITY in the target list is a TODO, either for later in 9.4 > development, or for 9.5. Some of the rest of us would like to hear those reasons, because my immediate reaction is that the patch must be broken by design. WITH ORDINALITY should not be needing to mess with the fundamental evaluation semantics of SRFs, but it sure sounds like it is doing so if that case doesn't work as expected. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers