Re: strange evaluation Window function and SRF functions? - Mailing list pgsql-hackers

From Thom Brown
Subject Re: strange evaluation Window function and SRF functions?
Date
Msg-id CAA-aLv5JQqzOgPrxR0JTp-nctw6jpBKzsKGc+TnqKOpN2mjVDg@mail.gmail.com
Whole thread Raw
In response to strange evaluation Window function and SRF functions?  (Pavel Stehule <pavel.stehule@gmail.com>)
Responses Re: strange evaluation Window function and SRF functions?  (David Johnston <polobo@yahoo.com>)
Re: strange evaluation Window function and SRF functions?  (Pavel Stehule <pavel.stehule@gmail.com>)
List pgsql-hackers
On 30 July 2012 17:19, Pavel Stehule <pavel.stehule@gmail.com> wrote:
Hello

I seen nice trick based on window function http://stackoverflow.com/questions/11700930/how-can-i-trim-a-text-array-in-postgresql

but isn't it example of wrong evaluation? Result of row_number is not correct

Looks right to me.  I guess the way to get the row_number they're after out of the result set would involve changing OVER () to OVER (ORDER BY unnest(myTextArrayColumn))

--
Thom

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: strange evaluation Window function and SRF functions?
Next
From: David Johnston
Date:
Subject: Re: strange evaluation Window function and SRF functions?