can connectby() deal with cyclic graph? - Mailing list pgsql-novice

From Zhenchang Xing
Subject can connectby() deal with cyclic graph?
Date
Msg-id Pine.SOL.4.44.0409241115500.20730-100000@stauffer.cs.ualberta.ca
Whole thread Raw
List pgsql-novice
hi,

I am a newcomer to PostgreSQL and SQL as well. I am doing my thesis in
university. My topic is about software evolution. So I am often faced with
such questions as:

1) the supertype and/or subtype of class/interface. I read PostgreSQL's
docs and some previous mails about connectby(). I understand it can help
me answer this question. But do i have to give a specific 'start_with'?
how can I query things like "the supertype of all classes"?

2) I understand connectby() can handle hierarchy/tree structure. How
about cyclic graph? For example, i have several classes, A, B, C, D.
A uses B, B uses C, C uses D, and finally D uses A. Starting from class
A, can connectby() return me A uses B, A uses C, A uses D, and stop
when it detect D uses A?

thanks so much.
zhenchang


pgsql-novice by date:

Previous
From: Christian Armeanu
Date:
Subject: Using PERFORM in plpgsql throws compile errors
Next
From: Neacal
Date:
Subject: Calculation Functions between Columns