Changeset: 2c971f6cd0d6 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=2c971f6cd0d6
Modified Files:
        clients/Tests/exports.stable.out
        sql/server/Makefile.ag
        sql/server/rel_optimizer.c
Branch: default
Log Message:

handle more types in partition elimination code


diffs (66 lines):

diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out
--- a/clients/Tests/exports.stable.out
+++ b/clients/Tests/exports.stable.out
@@ -1588,6 +1588,7 @@ str PCREreplace_wrap(str *res, const str
 str PCREsql2pcre(str *ret, const str *pat, const str *esc);
 str PROFexitClient(Client c);
 str PROFinitClient(Client c);
+str QLOGappend(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci);
 str QLOGcall(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci);
 void QLOGcalls(BAT **r);
 void QLOGcatalog(BAT **r);
@@ -1596,7 +1597,6 @@ str QLOGdisable(void *ret);
 str QLOGempty(void *ret);
 str QLOGenable(void *ret);
 str QLOGenableThreshold(void *ret, int *threshold);
-str QLOGinsert(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci);
 int QLOGisset(void);
 str QLOGissetFcn(int *ret);
 str QOTclrdebugOptimizers(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr 
pci);
@@ -2152,7 +2152,6 @@ int initTrace(void);
 int inlineMALblock(MalBlkPtr mb, int pc, MalBlkPtr mc);
 str inplaceRef;
 void insertInstruction(MalBlkPtr mb, InstrPtr p, int pc);
-str insertRef;
 void insertSymbol(Module scope, Symbol prg);
 str instruction2str(MalBlkPtr mb, MalStkPtr stl, InstrPtr p, int hidden);
 str instructionCall(MalBlkPtr mb, InstrPtr p, str s, str base, size_t len);
diff --git a/sql/server/Makefile.ag b/sql/server/Makefile.ag
--- a/sql/server/Makefile.ag
+++ b/sql/server/Makefile.ag
@@ -8,6 +8,7 @@
 
 INCLUDES = ../include ../common ../storage \
                   ../../monetdb5/mal \
+                  ../../monetdb5/modules/atoms \
                   ../../monetdb5/extras/rapi \
                   ../../clients/mapilib \
                   ../../common/options \
diff --git a/sql/server/rel_optimizer.c b/sql/server/rel_optimizer.c
--- a/sql/server/rel_optimizer.c
+++ b/sql/server/rel_optimizer.c
@@ -19,6 +19,7 @@
 #ifdef HAVE_HGE
 #include "mal.h"               /* for have_hge */
 #endif
+#include "mtime.h"
 
 #define new_func_list(sa) sa_list(sa)
 #define new_col_list(sa) sa_list(sa)
@@ -6856,14 +6857,14 @@ exp_range_overlap( mvc *sql, sql_exp *e,
                if (emax->data.val.shval < cmin->data.val.shval || 
emin->data.val.shval > cmax->data.val.shval)
                        return 0;
        }
-       if (t->type->localtype == TYPE_int) {
+       if (t->type->localtype == TYPE_int || t->type->localtype == TYPE_date) {
                atom *cmin = atom_general(sql->sa, t, min);
                atom *cmax = atom_general(sql->sa, t, max);
 
                if (emax->data.val.ival < cmin->data.val.ival || 
emin->data.val.ival > cmax->data.val.ival)
                        return 0;
        }
-       if (t->type->localtype == TYPE_lng) {
+       if (t->type->localtype == TYPE_lng || t->type->localtype == 
TYPE_timestamp) {
                atom *cmin = atom_general(sql->sa, t, min);
                atom *cmax = atom_general(sql->sa, t, max);
 
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to