Re: assorted problems with intarray and other GiST contribs.

From: PFC <lists(at)boutiquenumerique(dot)com>
To: "Oleg Bartunov" <oleg(at)sai(dot)msu(dot)su>
Cc: pgsql-sql(at)postgresql(dot)org, teodor(at)sigaev(dot)ru
Subject: Re: assorted problems with intarray and other GiST contribs.
Date: 2005-06-26 17:56:08
Message-ID: op.sszn3uk9th1vuj@localhost
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql


Thanks for the quick response !

>> * int_array_aggregate crashes
>
> I don't remember this function :)

You mean it's not part of intarray contrib ?
I thought so !
Sorry !
Then who's responsible for maintenance of it ?

> int4 nlevel(ltree) - returns level of the node.

I had missed this one.
The summer heat has burnt by brain it seems ;)
>
>> - access it like an array (ie. get element N).
>
> subltree, subpath

I know, but I was hoping for something like :
myltree[pos]

instead of the usable, but a bit huge, and probably slower :
ltree2text(subltree(myltree, pos-1,pos ));

>> Also a function returning the comon prefix between two ltrees would be
>> really useful.
>
> ltree lca(ltree,ltree,...) (up to 8 arguments)
> ltree lca(ltree[])
> Returns Lowest Common Ancestor (lca)

I know, too, but :

test=> SELECT lca( '1.2.3'::ltree, '1.2.4'::ltree );
lca
-----
1.2
(1 ligne)

test=> SELECT lca( '1.2.3'::ltree, '1.2'::ltree );
lca
-----
1
(1 ligne)

In the case of the 'longest common prefix' I'd need the second SELECT to
return the same as the first. This is to determine a 'parent' path that
includes a bunch of other paths, in that case, if the parent is part of
the original set, I get the parent's parent instead of what I want.

> Have you read README.ltree ?

Yes ! But I had missed nlevel() to my shame.

thanks !

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Michael Fuhr 2005-06-26 18:25:40 Re: assorted problems with intarray and other GiST contribs.
Previous Message Oleg Bartunov 2005-06-26 17:41:51 Re: assorted problems with intarray and other GiST contribs.