Re: graphs in PostgreSQL
От
Sean Davis
Тема
Re: graphs in PostgreSQL
Дата
Msg-id
BF73F900.10A96%sdavis2@mail.nih.gov
Ответ на
graphs in PostgreSQL (Ivan Yu. Zolotukhin)
Список
Дерево обсуждения
graphs in PostgreSQL "Ivan Yu. Zolotukhin" <iz@itpeople.ru>
Re: graphs in PostgreSQL Brent Wood <b.wood@niwa.co.nz>
Re: graphs in PostgreSQL Sean Davis <sdavis2@mail.nih.gov>
On 10/13/05 8:27 AM, "Ivan Yu. Zolotukhin" wrote: > Hello, > > I'm trying to organize storage and processing of a graph (pretty spare, > 100,000 vertices and 5,000,000 edges) with PostgreSQL. > > I have two main problems: > - standart problem of finding all shortest paths between two given vertices; > - search thru vertices' properties with ordering by path lengths from > given vertix. > > So, basically, I need to decide what additional data (some preprocessed > data about a graph or indexes) I need to store, how to store it, and how > maintain it when graph changes. > > It seems that the second problem (ordering by path length) requires to > store all path lengths between all vertices pairs (roadmap), that is > very expensive to maintain. > > I would appreciate any suggestions... Try googling for "transitive closure SQL" for some hits on the subject. The following website describes how some folks have stored a DAG for a biological system: http://www.godatabase.org/dev/sql/doc/godb-sql-doc.html I don't know if any folks from the CHADO (http://www.gmod.org/schema/index.shtml) project can comment on computing the transitive closure using stored procedures, but I think they do that for their project. Sean
В списке pgsql-general по дате отправления