3 ms·
PostgreSQL has a built-in ltree contrib datatype. Wouldn't that work just as well?
by scg 12y ago
PostgreSQL has a built-in ltree contrib datatype. Wouldn't that work just as well?
- gtaylor 12y agoltree isn't going to be a one-size-fits-all if you need more than one or two simple sorting conditions. Also, since ltree is really a glorified char field, you end up sorting by character ordinals instead of full values. Of course you can slice and dice the ltree string up, but at what point do you just use a CTE?