Update of /cvsroot/monetdb/pathfinder/compiler/algebra/prop
In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv31089/algebra/prop

Modified Files:
      Tag: XQuery_0-24
        prop_icol.c 
Log Message:
-- Added missing checks to the CSE phase.
   (This fixes the last failing query of bug report #1983619.)


U prop_icol.c
Index: prop_icol.c
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/compiler/algebra/prop/prop_icol.c,v
retrieving revision 1.37.2.1
retrieving revision 1.37.2.2
diff -u -d -r1.37.2.1 -r1.37.2.2
--- prop_icol.c 28 May 2008 11:34:41 -0000      1.37.2.1
+++ prop_icol.c 5 Jun 2008 09:26:22 -0000       1.37.2.2
@@ -839,19 +839,19 @@
             PFarray_t  *lproj = n->sem.eqjoin_unq.lproj,
                        *rproj = n->sem.eqjoin_unq.rproj;
 
+            /* add both join columns to the inferred icols */
+            union_ (n->prop->l_icols, proj_at(lproj, 0).old);
+            union_ (n->prop->r_icols, proj_at(rproj, 0).old);
+
             /* rename icols columns from new to old */
-            for (unsigned int i = 0; i < PFarray_last (lproj); i++)
+            for (unsigned int i = 1; i < PFarray_last (lproj); i++)
                 if (in (n->prop->icols, proj_at(lproj, i).new))
                     union_ (n->prop->l_icols, proj_at(lproj, i).old);
 
             /* rename icols columns from new to old */
-            for (unsigned int i = 0; i < PFarray_last (rproj); i++)
+            for (unsigned int i = 1; i < PFarray_last (rproj); i++)
                 if (in (n->prop->icols, proj_at(rproj, i).new))
                     union_ (n->prop->r_icols, proj_at(rproj, i).old);
-
-            /* add both join columns to the inferred icols */
-            union_ (n->prop->l_icols, proj_at(lproj, 0).old);
-            union_ (n->prop->r_icols, proj_at(rproj, 0).old);
         }   break;
 
         case la_cross_mvd:


-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
Monetdb-pf-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-pf-checkins

Reply via email to