Search Postgresql Archives

Re: Hierarchical numeric data type

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

 



On Tue, Aug 6, 2013 at 2:36 PM, Derek Poon <derekp+pgsql@xxxxxxxxxx> wrote:
> The performance impact of the enhanced comparator would probably be negligible, compared to I/O bottlenecks.  A bigger issue would be backwards compatibility, especially for ltrees with existing btree indexes.
>
> Feedback?  Suggestions?

Use integer arrays. It works just like you need

select array_to_string(c, '.')
from (values (array[1,10,2]), (array[1,5,3])) as sq(c)
order by c;

 array_to_string
-----------------
 1.5.3
 1.10.2

and it is pretty fast when indexed.

-- 
Kind regards,
Sergey Konoplev
PostgreSQL Consultant and DBA

Profile: http://www.linkedin.com/in/grayhemp
Phone: USA +1 (415) 867-9984, Russia +7 (901) 903-0499, +7 (988) 888-1979
Skype: gray-hemp
Jabber: gray.ru@xxxxxxxxx


-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general




[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