BUG #13486: How can I sort unnest results? - Mailing list pgsql-bugs

From longzou@hotmail.com
Subject BUG #13486: How can I sort unnest results?
Date
Msg-id 20150704010545.1190.24623@wrigleys.postgresql.org
Whole thread Raw
Responses Re: BUG #13486: How can I sort unnest results?
List pgsql-bugs
The following bug has been logged on the website:

Bug reference:      13486
Logged by:          Long Zou
Email address:      longzou@hotmail.com
PostgreSQL version: 9.4.4
Operating system:   Mac OS X
Description:

I have a query that using the unnest function. But I don't know how to sort
the result.

For example:
select * from unnest(array[1,2,3,4,5,6], array[10,8,3,6,8,2], array['ab',
'dd','','dd','st']);
The result will have three columns and those name are 'unnest'. So, if I use
unnest as the order by cause, it will raise an error:
ERROR: ORDER BY "unnest" is ambiguous.

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #12379: pgbench should hint to pgbench -i
Next
From: jingwei_5107@qq.com
Date:
Subject: BUG #13487: GetBufferFromRing code bug