Re: array sort for varchar arrays?

From: Artacus <artacus(at)comcast(dot)net>
To: PGSQL <pgsql-general(at)postgresql(dot)org>
Subject: Re: array sort for varchar arrays?
Date: 2008-07-09 03:16:50
Message-ID: 48742DA2.8000607@comcast.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

> I'm likely overlooking something, but I can't seem to find a function to
> sort a varchar array. Something like "select
> sort('{y,z,x}'::varchar[])" => {'x','y','z'}.

You've got it right. On Pg 8.3.3 I get
SELECT sort(array['z','y','x']) -> {x,y,z}

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Artacus 2008-07-09 03:24:01 Getting source code for database objects
Previous Message Ow Mun Heng 2008-07-09 03:09:49 Re: Quick way to alter a column type?