Received: from localhost.localdomain (postgresql.org [64.49.215.8]) by localhost (Postfix) with ESMTP id 6001D475992 for ; Tue, 7 May 2002 07:03:19 -0400 (EDT) Received: from fepZ.post.tele.dk (fepz.post.tele.dk [195.41.46.133]) by postgresql.org (Postfix) with ESMTP id D0CF0475914 for ; Tue, 7 May 2002 07:03:17 -0400 (EDT) Received: from localhost.localdomain ([80.196.138.103]) by fepZ.post.tele.dk (InterMail vM.4.01.03.23 201-229-121-123-20010418) with ESMTP id <20020507110319.IQKT26021.fepZ.post.tele.dk@localhost.localdomain>; Tue, 7 May 2002 13:03:19 +0200 Subject: Re: Optimizing the implementation of an optimized tree From: Christian Rishoej To: Christopher Kings-Lynne , pgsql-sql@postgresql.org In-Reply-To: References: Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Mailer: Ximian Evolution 1.0.3 Date: 07 May 2002 13:03:19 +0200 Message-Id: <1020769399.889.10.camel@penelope.dyndns.dk> Mime-Version: 1.0 X-Archive-Number: 200205/42 X-Sequence-Number: 7678 On Tue, 2002-05-07 at 04:00, Christopher Kings-Lynne wrote: > Why not try Oleg and Teodor's tree module? > > http://cddb.sai.msu.su/~megera/postgres/gist/ > > You have to expend a little effort in implementing it as the README's in > Russian :) Still has examples tho. As far as I can tell Oleg and Teotor are doing *balanced* trees, and not trees usable for containing a hiearchy of nodes where each node can have 0-N children. It is my understanding that I cannot rely on the organization of a balanced tree - hence the name "balanced" (nodes are inserted where some algotithm thinks it fits in, not where I want it. Imagine if your directory-hiearchy on your filesystem was a balanced tree...). Does anyone have a clue on how to optimize triggers? Can I use another language than PL/PGSQL? Would C be crazy when I do lots of SQL's and no calculation in the trigger? Christian