From: | PFC <lists(at)boutiquenumerique(dot)com> |
---|---|
To: | "Oleg Bartunov" <oleg(at)sai(dot)msu(dot)su>, "Axel Straschil" <axel(at)straschil(dot)com> |
Cc: | pgsql-sql(at)postgresql(dot)org |
Subject: | Re: How to store directory like structures? |
Date: | 2005-04-03 19:57:29 |
Message-ID: | op.son9p3qhth1vuj@localhost |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
> you need to load ltree into your database !
> psql yourdb < ltree.sql
>
> use 'locate ltree.sql' to find if ltree is installed
Yeah, I remember now having to do that, but the binary module definitely
was here without having to do anything besides "emerge postgresql" :
peufeu(at)nyuu peufeu $ locate ltree.so
/usr/lib/postgresql/ltree.so
peufeu(at)nyuu peufeu $ locate ltree.sql
/usr/share/postgresql/contrib/ltree.sql
So just :
psql yourdb < /usr/share/postgresql/contrib/ltree.sql
And you should be OK.
Really this module is amazing. You can put a trigger on the table so
that, for instance, the path is created automatically from the element
name and the parent_id, that kind of things. I remember search was also
really fast and you can use complex queries without CONNECT BY...
From | Date | Subject | |
---|---|---|---|
Next Message | Greg Stark | 2005-04-03 20:35:28 | Re: Date/Time Conversion |
Previous Message | Oleg Bartunov | 2005-04-03 19:24:56 | Re: How to store directory like structures? |