I have looked over this addition, and I think I finally understand it. Given three tables, A, B, C, which join as A->B, B->C, C->A, you can really join them as A->B->C, and A->C->B. What full disjunction does is to perform both of those joins, and return a one row for each join. Here is an example from the README:
Example of an input and output of a full disjunctions: INPUT: --A---|---B---|---C-- X---Y-|-Y---Z-|-X---Z a-|-b-|-b-|-c-|-a-|-d A,B and C are relations. X,Y and Z are attributes. a,b,c and d are values. Note that A,B and C are connected in a cycle. That is: A is connected to B on attribute Y, B is connected to C on attribute Z, C is connected to A on attribute X. The output of the full disjunctions FD(A,B,C): FD X---Y---Z a-|-b-|-c a-|-b-|-d This code is pretty complex, so I can see why it should be in /contrib. Are there reasonable use cases for this capability? --------------------------------------------------------------------------- Tzahi Fadida wrote: > Hi, > I wish to add the fulldisjunctions function to the contrib. > With the help of Jonah, we (or rather he :) created a patch with > regression tests. The function is finished programmatically but > still a little more code documentation touches and improved error messages > are needed. All the rest was extensively tested. > > Attached is the patch. > > Works great. Just compiled from a fresh cvs which i patched with the > attached diff. ran the fulldijsjunction.sql in the > share/contrib/fulldisjunction and let it run and it works great. > 10x. > > -- > Regards, > ????????Tzahi. > -- > Tzahi Fadida > Blog: http://tzahi.blogsite.org | Home Site: http://tzahi.webhop.info > WARNING TO SPAMMERS: ?see at > http://members.lycos.co.uk/my2nis/spamwarning.html [ Attachment, skipping... ] > > ---------------------------(end of broadcast)--------------------------- > TIP 3: Have you checked our extensive FAQ? > > http://www.postgresql.org/docs/faq -- Bruce Momjian [EMAIL PROTECTED] EnterpriseDB http://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. + ---------------------------(end of broadcast)--------------------------- TIP 4: Have you searched our list archives? http://archives.postgresql.org