Re: NESTED RELATIONAL DATABASES

From: Paul Brown <pbrown_at_triplerock.CS.Berkeley.EDU>
Date: 1997/10/06
Message-ID: <61b5pp$d4h$1_at_agate.berkeley.edu>#1/1


Jeremy Rickard (Jeremy_at_jbdr.demon.co.uk) wrote: : Is that so obvious - you could use UDFs for this too?

  Yes.

  When you add a UDT that can be indexed with a b-tree, for example,  you simply need to write a function cmp(T,T') that returns  -1 if ( T < T' ), 0 if ( T == T' ), and 1 if ( T > T' ). Then the  generic b-tree algorithm can deal with the data. This general scheme  works within Postgres, (and Illustra, and the Informix Universal Server, and  IBM's DB/2).

  Of course, this suggests that the overhead of executing the  cmp() routine must be very, very small, and it must run really,  really fast. This means that the routine needs to run 'as close to  the silicon as possible' (i.e. compiled) and it needs to run in  the context of the DBMS process.

  KR

   Pb    Received on Mon Oct 06 1997 - 00:00:00 CEST

Original text of this message