Search Postgresql Archives

Re: Order by lower(column-alias) doesn't work...

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Andreas Joseph Krogh <andreas@xxxxxxxxxx> writes:
> Is there a way to define "sorting-rules" on custom-types so that I can have 
> ORDER BY <my_array_of_custom_types_alias> and PG will pick my custom odering? 

You'd have to write your own type, which would be a lotta work :-(.

A possible partial answer is to define the composite type as

	firstname citext, lastname citext, other-fields-here

and then the regular composite-type comparison rule would give you
approximately what you said you wanted ... but only approximately.

			regards, tom lane






[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux