Changeset: 94e3b1a21a8d for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=94e3b1a21a8d
Modified Files:
        monetdb5/optimizer/opt_mergetable.c
        
sql/test/BugTracker-2009/Tests/segfault_when_quitting_debugger.SF-2538837.stable.out
        sql/test/bugs/Tests/select_select_bug.stable.out
        sql/test/mergetables/Tests/part-elim.stable.out
Branch: default
Log Message:

approved output


diffs (113 lines):

diff --git a/monetdb5/optimizer/opt_mergetable.c 
b/monetdb5/optimizer/opt_mergetable.c
--- a/monetdb5/optimizer/opt_mergetable.c
+++ b/monetdb5/optimizer/opt_mergetable.c
@@ -1859,7 +1859,8 @@ cleanup:
     }
     /* keep all actions taken as a post block comment */
     snprintf(buf,256,"%-20s actions=%2d time=" LLFMT " 
usec","mergetable",actions,GDKusec() - usec);
-    newComment(mb,buf);
+    if ( mb->errors == 0) 
+        newComment(mb,buf);
 
        return actions;
 }
diff --git 
a/sql/test/BugTracker-2009/Tests/segfault_when_quitting_debugger.SF-2538837.stable.out
 
b/sql/test/BugTracker-2009/Tests/segfault_when_quitting_debugger.SF-2538837.stable.out
--- 
a/sql/test/BugTracker-2009/Tests/segfault_when_quitting_debugger.SF-2538837.stable.out
+++ 
b/sql/test/BugTracker-2009/Tests/segfault_when_quitting_debugger.SF-2538837.stable.out
@@ -22,7 +22,7 @@ Ready.
 
 #debug select * from tables;
 mdb>#X_1=0@0:void := user.s1_1();
-mdb>#X_159=0@0:void := querylog.define("debug select * from 
tables;","default_pipe",631);
+mdb>#X_159=0@0:void := querylog.define("debug select * from 
tables;","default_pipe",375);
 
 # 16:24:01 >  
 # 16:24:01 >  "Done."
diff --git a/sql/test/bugs/Tests/select_select_bug.stable.out 
b/sql/test/bugs/Tests/select_select_bug.stable.out
--- a/sql/test/bugs/Tests/select_select_bug.stable.out
+++ b/sql/test/bugs/Tests/select_select_bug.stable.out
@@ -29,7 +29,7 @@ Ready.
 #SELECT (SELECT current_timestamp), count(DISTINCT mmsi) FROM vessels;
 % .L1, sys.L2 # table_name
 % L1,  L2 # name
-% tinyint,     wrd # type
+% tinyint,     bigint # type
 % 1,   1 # length
 [ 1,   0       ]
 #drop table vessels;
diff --git a/sql/test/mergetables/Tests/part-elim.stable.out 
b/sql/test/mergetables/Tests/part-elim.stable.out
--- a/sql/test/mergetables/Tests/part-elim.stable.out
+++ b/sql/test/mergetables/Tests/part-elim.stable.out
@@ -79,6 +79,72 @@ project (
 | | table(sys.mt2) [ test.id, test.posx, test.%TID% NOT NULL ] COUNT 
 | ) [ bigint "1" <= test.id <= bigint "1000" ]
 ) [ test.id, test.posx ]
+#declare l integer;
+#set l = 1;
+#declare h integer;
+#set h = 10000;
+#plan select * from test where id between l and h;
+% .plan # table_name
+% rel # name
+% clob # type
+% 106 # length
+union (
+| project (
+| | select (
+| | | table(sys.mt1) [ mt1.id as test.id, mt1.posx as test.posx, mt1.%TID% NOT 
NULL as test.%TID% ] COUNT 
+| | ) [ bigint[l] <= test.id <= bigint[h] ]
+| ) [ test.id, test.posx ],
+| project (
+| | select (
+| | | table(sys.mt2) [ mt2.id as test.id, mt2.posx as test.posx, mt2.%TID% NOT 
NULL as test.%TID% ] COUNT 
+| | ) [ bigint[l] <= test.id <= bigint[h] ]
+| ) [ test.id, test.posx ]
+) [ test.id, test.posx ]
+#set h = 1000;
+#plan select * from test where id between l and h;
+% .plan # table_name
+% rel # name
+% clob # type
+% 69 # length
+project (
+| select (
+| | table(sys.mt2) [ test.id, test.posx, test.%TID% NOT NULL ] COUNT 
+| ) [ bigint[l] <= test.id <= bigint[h] ]
+) [ test.id, test.posx ]
+#plan select * from test where id between 1 and 1000*10;
+% .plan # table_name
+% rel # name
+% clob # type
+% 106 # length
+union (
+| project (
+| | select (
+| | | table(sys.mt1) [ mt1.id as test.id, mt1.posx as test.posx, mt1.%TID% NOT 
NULL as test.%TID% ] COUNT 
+| | ) [ bigint "1" <= test.id <= bigint[sys.sql_mul(smallint "1000", tinyint 
"10")] ]
+| ) [ test.id, test.posx ],
+| project (
+| | select (
+| | | table(sys.mt2) [ mt2.id as test.id, mt2.posx as test.posx, mt2.%TID% NOT 
NULL as test.%TID% ] COUNT 
+| | ) [ bigint "1" <= test.id <= bigint[sys.sql_mul(smallint "1000", tinyint 
"10")] ]
+| ) [ test.id, test.posx ]
+) [ test.id, test.posx ]
+#plan select * from test where id between 1 and 100*10;
+% .plan # table_name
+% rel # name
+% clob # type
+% 106 # length
+union (
+| project (
+| | select (
+| | | table(sys.mt1) [ mt1.id as test.id, mt1.posx as test.posx, mt1.%TID% NOT 
NULL as test.%TID% ] COUNT 
+| | ) [ bigint "1" <= test.id <= bigint[sys.sql_mul(smallint "100", tinyint 
"10")] ]
+| ) [ test.id, test.posx ],
+| project (
+| | select (
+| | | table(sys.mt2) [ mt2.id as test.id, mt2.posx as test.posx, mt2.%TID% NOT 
NULL as test.%TID% ] COUNT 
+| | ) [ bigint "1" <= test.id <= bigint[sys.sql_mul(smallint "100", tinyint 
"10")] ]
+| ) [ test.id, test.posx ]
+) [ test.id, test.posx ]
 #drop table test;
 #drop table mt1;
 #drop table mt2;
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to