Re: trees, trees, trees

From: Gerard H. Pille <ghp_at_skynet.be>
Date: Sun, 24 Jun 2012 18:56:32 +0200
Message-ID: <4fe746a0$0$3108$ba620e4c_at_news.skynet.be>



geos wrote:
> Gerard H. Pille wrote:
>> I've been keeping both my eyes on performance in programming for over 35 years now. Of course,
>> I can only do as much as your design allows. Given the correct indexing, tree walks can be
>> performant enough. You wouldn't want me to write the select statement for you, would you?
>
> sure I would. why wouln't ask for more explicit help when struggling with the problem for some
> time? writing a statement that can be analyzed is great help too, especially a query from
> someone with such big experience compared to mine. the information about hierarchical queries
> was obvious from the beginning.
>
> anyway, if you would like to help here is a complete script that fills table with sample data
> and expected result:
>
> http://geos2005.republika.pl/table.sql
> http://geos2005.republika.pl/result.jpg
>
> GRP column in the table is just helpful for spotting a groups of records but it can not be used
> in a query. generally the entries in the table are edges of a graph, can be many nodes in a
> graph, can be connected in any way between each other allowing loops.
>
> thank you,
> geos
>

I'm not sure I'll be able to help you. I did understand your original requirements, but now you've lost me. I do not know what "edges of a graph" are. What are columns p and c in your table? What do they contain? Received on Sun Jun 24 2012 - 11:56:32 CDT

Original text of this message