Niels,
does this replace a merge of your Oct2012 checkin to the Feb2013 branch?
Before this checkin, the merge worked without any conflicts (I did not test, whether/how it works).
After this checkin, the merge fails with conflicts (I did not check the details).
Thanks!
Stefan
Niels Nes wrote:
Changeset: ee6e585e72c5 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=ee6e585e72c5
Modified Files:
sql/backends/monet5/Tests/optimizers.stable.out
sql/backends/monet5/UDF/Tests/udf-fuse.stable.out
sql/backends/monet5/UDF/Tests/udf-reverse.stable.out
sql/server/sql_mvc.c
sql/server/sql_parser.y
sql/server/sql_qc.c
sql/test/ADT2006/Tests/bram.stable.out
sql/test/BugDay_2005-10-06_2.8/Tests/string_quotes.SF-919539.stable.out
sql/test/BugDay_2005-10-06_2.9.3/Tests/UNION_JOIN_vs_plain_set_UNION-2.SF-920585.stable.out
sql/test/BugDay_2005-10-06_2.9.3/Tests/basic_arithmetics.SF-922252.stable.out
sql/test/BugDay_2005-10-06_2.9.3/Tests/case.SF-929151.stable.out
sql/test/BugDay_2005-10-06_2.9.3/Tests/jdbc_crashes_on_getTables.SF_944316.stable.out
sql/test/BugDay_2005-10-06_2.9.3/Tests/simple_union.SF-1005596.stable.out
sql/test/BugDay_2005-10-06_2.9.3/Tests/variable_arg_substring.SF_942981.stable.out
sql/test/BugDay_2005-11-09_2.8/Tests/crash_in_case.SF-1097749.stable.out
sql/test/BugDay_2005-11-09_2.9.3/Tests/sql_server_crash.SF-1080024.stable.out
sql/test/BugDay_2005-11-09_2.9.3/Tests/union-duplicates.SF-1119186.stable.out
sql/test/BugTracker-2009/Tests/AVG_of_SQRT.SF-2757642.stable.out
sql/test/BugTracker-2009/Tests/IS_NULL_in_CASE.stable.out
sql/test/BugTracker-2009/Tests/group_by_on_values.SF-2837561.stable.out
sql/test/BugTracker-2009/Tests/not_equal.SF-2678502.stable.out
sql/test/BugTracker-2009/Tests/old_views_incorrectly_reused.SF-2863804.stable.out
sql/test/BugTracker-2009/Tests/push_select_down_crash.stable.out
sql/test/BugTracker-2009/Tests/utf8_bug.SF-2822855.stable.out
sql/test/BugTracker-2010/Tests/LIMIT_OFFSET_big-endian.Bug-2622.stable.out
sql/test/BugTracker-2010/Tests/crash_on_where_in.Bug-2333.stable.out
sql/test/BugTracker-2010/Tests/group-by_ordered_column.Bug-2564.stable.out
sql/test/BugTracker-2010/Tests/mat.slice_limit1.Bug-2645.stable.out
sql/test/BugTracker-2010/Tests/order_by_on_single_row_view.SF-2950453.stable.out
sql/test/BugTracker-2010/Tests/substring_display_width.Bug-2683.stable.out
sql/test/BugTracker-2011/Tests/case-when-alias.Bug-2848.stable.out
sql/test/BugTracker-2012/Tests/predicate_select.Bug-3090.stable.err
sql/test/BugTracker-2012/Tests/rewrite_like_into_likesubselect.Bug-3179.stable.out
sql/test/BugTracker/Tests/assert_fails_on_algebra_version.SF-2019349.stable.out
sql/test/BugTracker/Tests/bind_with_cast.SF-1720934.stable.err
sql/test/BugTracker/Tests/crash_on_delete.SF-1639108.stable.out
sql/test/BugTracker/Tests/crash_on_delete.SF-1651567.stable.out
sql/test/BugTracker/Tests/crash_on_insert.SF-1639113.stable.out
sql/test/BugTracker/Tests/insert_not_exists.SF-1380287.stable.out
sql/test/Dependencies/Tests/Dependencies.stable.out
sql/test/Skyserver/Tests/Skyserver.stable.out
sql/test/Tests/coalesce.stable.out
sql/test/Tests/decimal2.stable.out
sql/test/Tests/setoptimizer.stable.out
sql/test/VOC/Tests/VOC.stable.out
sql/test/bugs/Tests/crash_order_by.stable.out
sql/test/bugs/Tests/select_from_values.stable.out
sql/test/bugs/Tests/simple_view.stable.out
sql/test/bugs/Tests/subselect_multiple_unionall_where_1=1-bug-sf-1005596.stable.out
sql/test/bugs/Tests/subselect_single_value-bug-sf-941791.stable.out
sql/test/bugs/Tests/subselect_union-bug-sf-941826.stable.out
sql/test/bugs/Tests/unicode_varchar-bug-sf-1041324_JdbcClient.stable.out
sql/test/bugs/Tests/unicode_varchar-bug-sf-1041324_MapiClient.stable.out
sql/test/bugs/Tests/union_all-bug-sf-941788.stable.out
sql/test/bugs/Tests/union_all_where_1=1-bug-sf-936386.stable.out
sql/test/leaks/Tests/check0.stable.out
sql/test/leaks/Tests/check1.stable.out
sql/test/leaks/Tests/check2.stable.out
sql/test/leaks/Tests/check3.stable.out
sql/test/leaks/Tests/check4.stable.out
sql/test/leaks/Tests/check5.stable.out
sql/test/leaks/Tests/drop3.stable.out
sql/test/leaks/Tests/temp1.stable.out
sql/test/leaks/Tests/temp2.stable.out
sql/test/leaks/Tests/temp3.stable.out
sql/test/pg_regress/Tests/char.stable.out
sql/test/pg_regress/Tests/strings_concat.stable.out
sql/test/pg_regress/Tests/text.stable.out
sql/test/pg_regress/Tests/varchar.stable.out
sql/test/rdf/Tests/q2_28_v.stable.out
sql/test/rdf/Tests/q2_v.stable.out
sql/test/rdf/Tests/q3_28_v.stable.out
sql/test/rdf/Tests/q3_v.stable.out
sql/test/rdf/Tests/q4_28_v.stable.out
sql/test/rdf/Tests/q4_v.stable.out
sql/test/rdf/Tests/q6_28_v.stable.out
sql/test/rdf/Tests/q6_v.stable.out
Branch: Feb2013
Log Message:
ported fix to the query cache from Oct2012
diffs (truncated from 3392 to 300 lines):
diff --git a/sql/backends/monet5/Tests/optimizers.stable.out b/sql/backends/monet5/Tests/optimizers.stable.out
--- a/sql/backends/monet5/Tests/optimizers.stable.out
+++ b/sql/backends/monet5/Tests/optimizers.stable.out
@@ -47,31 +47,31 @@ Ready.
#select 'optimizer test:',optimizer;
% ., . # table_name
% single_value, single_value # name
-% char, varchar # type
+% varchar, varchar # type
% 15, 12 # length
[ "optimizer test:", "default_pipe" ]
#select 'optimizer off test:',optimizer;
% ., . # table_name
% single_value, single_value # name
-% char, varchar # type
+% varchar, varchar # type
% 19, 12 # length
[ "optimizer off test:", "default_pipe" ]
#select 'optimizer on test:',optimizer;
% ., . # table_name
% single_value, single_value # name
-% char, varchar # type
+% varchar, varchar # type
% 18, 12 # length
[ "optimizer on test:", "default_pipe" ]
#select 'optimizer <empty> test:',optimizer;
% ., . # table_name
% single_value, single_value # name
-% char, varchar # type
+% varchar, varchar # type
% 23, 12 # length
[ "optimizer <empty> test:", "default_pipe" ]
#select 'done';
% . # table_name
% single_value # name
-% char # type
+% varchar # type
% 4 # length
[ "done" ]
diff --git a/sql/backends/monet5/UDF/Tests/udf-fuse.stable.out b/sql/backends/monet5/UDF/Tests/udf-fuse.stable.out
--- a/sql/backends/monet5/UDF/Tests/udf-fuse.stable.out
+++ b/sql/backends/monet5/UDF/Tests/udf-fuse.stable.out
@@ -45,12 +45,10 @@ end s0_1;
% mal # name
% clob # type
% 71 # length
-function user.s2_1{autoCommit=true}(A0:sht,A1:sht):void;
+function user.s1_1{autoCommit=true}(A0:sht,A1:sht):void;
X_4 := udf.fuse(A0,A1);
sql.exportValue(1,".","fuse_single_value":str,"int",32,0,6,X_4,"");
-end s2_1;
-# optimizer.mitosis()
-# optimizer.dataflow()
+end s1_1;
#select fuse(1000,2000);
% . # table_name
% fuse_single_value # name
@@ -62,12 +60,10 @@ end s2_1;
% mal # name
% clob # type
% 74 # length
-function user.s4_1{autoCommit=true}(A0:int,A1:int):void;
+function user.s2_1{autoCommit=true}(A0:int,A1:int):void;
X_4 := udf.fuse(A0,A1);
sql.exportValue(1,".","fuse_single_value":str,"bigint",64,0,6,X_4,"");
-end s4_1;
-# optimizer.mitosis()
-# optimizer.dataflow()
+end s2_1;
#select fuse(1000000,2000000);
% . # table_name
% fuse_single_value # name
@@ -97,7 +93,7 @@ end s4_1;
% mal # name
% clob # type
% 60 # length
-function user.s11_1{autoCommit=true}():void;
+function user.s5_1{autoCommit=true}():void;
X_2 := sql.mvc();
X_3:bat[:oid,:oid] := sql.tid(X_2,"sys","udf_fuse");
X_6 := sql.bind(X_2,"sys","udf_fuse","a",0);
@@ -115,15 +111,13 @@ function user.s11_1{autoCommit=true}():v
sql.rsColumn(X_25,"sys.","fuse_a","smallint",16,0,X_23);
X_30 := io.stdout();
sql.exportResult(X_30,X_25);
-end s11_1;
-# optimizer.mitosis()
-# optimizer.dataflow()
+end s5_1;
#explain select fuse(c,d) from udf_fuse;
% .explain # table_name
% mal # name
% clob # type
% 57 # length
-function user.s12_1{autoCommit=true}():void;
+function user.s6_1{autoCommit=true}():void;
X_2 := sql.mvc();
X_3:bat[:oid,:oid] := sql.tid(X_2,"sys","udf_fuse");
X_6 := sql.bind(X_2,"sys","udf_fuse","c",0);
@@ -141,15 +135,13 @@ function user.s12_1{autoCommit=true}():v
sql.rsColumn(X_25,"sys.","fuse_c","int",32,0,X_23);
X_30 := io.stdout();
sql.exportResult(X_30,X_25);
-end s12_1;
-# optimizer.mitosis()
-# optimizer.dataflow()
+end s6_1;
#explain select fuse(e,f) from udf_fuse;
% .explain # table_name
% mal # name
% clob # type
% 58 # length
-function user.s13_1{autoCommit=true}():void;
+function user.s7_1{autoCommit=true}():void;
X_2 := sql.mvc();
X_3:bat[:oid,:oid] := sql.tid(X_2,"sys","udf_fuse");
X_6 := sql.bind(X_2,"sys","udf_fuse","e",0);
@@ -167,9 +159,7 @@ function user.s13_1{autoCommit=true}():v
sql.rsColumn(X_25,"sys.","fuse_e","bigint",64,0,X_23);
X_30 := io.stdout();
sql.exportResult(X_30,X_25);
-end s13_1;
-# optimizer.mitosis()
-# optimizer.dataflow()
+end s7_1;
#select fuse(a,b) from udf_fuse;
% sys. # table_name
% fuse_a # name
diff --git a/sql/backends/monet5/UDF/Tests/udf-reverse.stable.out b/sql/backends/monet5/UDF/Tests/udf-reverse.stable.out
--- a/sql/backends/monet5/UDF/Tests/udf-reverse.stable.out
+++ b/sql/backends/monet5/UDF/Tests/udf-reverse.stable.out
@@ -82,7 +82,7 @@ end s0_1;
% mal # name
% clob # type
% 62 # length
-function user.s7_1{autoCommit=true}():void;
+function user.s3_1{autoCommit=true}():void;
X_2 := sql.mvc();
X_3:bat[:oid,:oid] := sql.tid(X_2,"sys","udf_reverse");
X_6 := sql.bind(X_2,"sys","udf_reverse","x",0);
@@ -95,7 +95,7 @@ function user.s7_1{autoCommit=true}():vo
sql.rsColumn(X_18,"sys.","reverse_x":str,"clob",0,0,X_16);
X_22 := io.stdout();
sql.exportResult(X_22,X_18);
-end s7_1;
+end s3_1;
#select reverse(x) from udf_reverse;
% sys. # table_name
% reverse_x # name
diff --git a/sql/server/sql_mvc.c b/sql/server/sql_mvc.c
--- a/sql/server/sql_mvc.c
+++ b/sql/server/sql_mvc.c
@@ -193,8 +193,6 @@ mvc_trans(mvc *m)
qc_clean(m->qc);
}
}
- if (m->session->active)
- m->type = Q_TRANS;
store_unlock();
}
diff --git a/sql/server/sql_parser.y b/sql/server/sql_parser.y
--- a/sql/server/sql_parser.y
+++ b/sql/server/sql_parser.y
@@ -3954,7 +3954,7 @@ literal:
string { char *s = sql2str($1);
int len = _strlen(s);
sql_subtype t;
- sql_find_subtype(&t, "char", len, 0 );
+ sql_find_subtype(&t, "varchar", len, 0 );
$$ = _newAtomNode( _atom_string(&t, s)); }
| HEXADECIMAL { int len = _strlen($1), i = 2, err = 0;
diff --git a/sql/server/sql_qc.c b/sql/server/sql_qc.c
--- a/sql/server/sql_qc.c
+++ b/sql/server/sql_qc.c
@@ -143,6 +143,11 @@ param_cmp(sql_subtype *t1, sql_subtype *
if (t1->scale != t2->scale)
return -1;
+
+ if (t1->type->eclass == EC_NUM && t2->type->eclass == EC_NUM &&
+ t1->digits >= t2->digits)
+ return 0;
+
res = is_subtype(t2, t1);
if (!res)
return -1;
@@ -178,7 +183,7 @@ param_list_cmp(sql_subtype *typelist, at
if ((!((at->type->eclass == EC_DEC ||
at->type->eclass == EC_NUM) &&
tp->type->eclass == EC_FLT)) &&
- (!(EC_VARCHAR(tp->type->eclass) &&
+ (!(EC_VARCHAR(tp->type->eclass) &&
EC_VARCHAR(at->type->eclass) &&
(!tp->digits ||
tp->digits >= at->digits))) &&
diff --git a/sql/test/ADT2006/Tests/bram.stable.out b/sql/test/ADT2006/Tests/bram.stable.out
--- a/sql/test/ADT2006/Tests/bram.stable.out
+++ b/sql/test/ADT2006/Tests/bram.stable.out
@@ -458,7 +458,7 @@ Ready.
#(SELECT 'Major' AS grade, count(na
% ., .inspector # table_name
% grade, inspectors # name
-% char, wrd # type
+% varchar, wrd # type
% 9, 1 # length
[ "Detective", 3 ]
[ "Constable", 3 ]
@@ -475,7 +475,7 @@ Ready.
# + cast(substring(length from (position('\'' in length) + 1) for (position('"' in length) + 1)) AS integer)) as height from victim v
% .L1, . # table_name
% L1, average_height # name
-% char, char # type
+% varchar, varchar # type
% 6, 4 # length
[ "blonde", "5'7\"" ]
[ "brown", "5'5\"" ]
diff --git a/sql/test/BugDay_2005-10-06_2.8/Tests/string_quotes.SF-919539.stable.out b/sql/test/BugDay_2005-10-06_2.8/Tests/string_quotes.SF-919539.stable.out
--- a/sql/test/BugDay_2005-10-06_2.8/Tests/string_quotes.SF-919539.stable.out
+++ b/sql/test/BugDay_2005-10-06_2.8/Tests/string_quotes.SF-919539.stable.out
@@ -20,12 +20,12 @@ Ready.
% . # table_name
% single_value # name
-% char # type
+% varchar # type
% 2 # length
[ "aa" ]
% . # table_name
% single_value # name
-% char # type
+% varchar # type
% 3 # length
[ "a'a" ]
diff --git a/sql/test/BugDay_2005-10-06_2.9.3/Tests/UNION_JOIN_vs_plain_set_UNION-2.SF-920585.stable.out b/sql/test/BugDay_2005-10-06_2.9.3/Tests/UNION_JOIN_vs_plain_set_UNION-2.SF-920585.stable.out
--- a/sql/test/BugDay_2005-10-06_2.9.3/Tests/UNION_JOIN_vs_plain_set_UNION-2.SF-920585.stable.out
+++ b/sql/test/BugDay_2005-10-06_2.9.3/Tests/UNION_JOIN_vs_plain_set_UNION-2.SF-920585.stable.out
@@ -101,7 +101,7 @@ Ready.
[ "users", "SELECT u.\"t\" AS \"name\", ui.\"fullname\", ui.\"default_schema\" FROM \"sys\".\"db_users\" AS u, \"sys\".\"db_user_info\" AS ui WHERE u.\"h\" = ui.\"id\" AND u.\"h\" NOT IN (SELECT s.\"h\" FROM \"sys\".\"db_scens\" AS s WHERE s.\"t\" NOT LIKE 'sql');", false, true, 0, 0 ]
% .tables, .tables, .tables, .tables, .tables, .tables, .tables, .tables, .tables, .tables # table_name
% table_cat, table_schem, table_name, table_type, remarks, type_cat, type_schem, type_name, self_referencing_col_name, ref_generation # name
-% char, varchar, varchar, char, varchar, char, char, char, char, char # type
+% varchar, varchar, varchar, varchar, varchar, varchar, varchar, varchar, varchar, varchar # type
% 4, 3, 8, 12, 222, 4, 4, 4, 2, 6 # length
[ "null", "sys", "columns", "SYSTEM TABLE", "", "null", "null", "null", "id", "SYSTEM" ]
[ "null", "sys", "db_scens", "SYSTEM TABLE", "", "null", "null", "null", "id", "SYSTEM" ]
diff --git a/sql/test/BugDay_2005-10-06_2.9.3/Tests/basic_arithmetics.SF-922252.stable.out b/sql/test/BugDay_2005-10-06_2.9.3/Tests/basic_arithmetics.SF-922252.stable.out
--- a/sql/test/BugDay_2005-10-06_2.9.3/Tests/basic_arithmetics.SF-922252.stable.out
+++ b/sql/test/BugDay_2005-10-06_2.9.3/Tests/basic_arithmetics.SF-922252.stable.out
@@ -63,8 +63,9 @@ Ready.
[ 1 ]
% . # table_name
% single_value # name
-% char # type
-% 1 # length
+% varchar # type
+% 0 # length
+#select * from my_table where 1 = 0;
% sys.my_table # table_name
% att # name
% int # type
diff --git a/sql/test/BugDay_2005-10-06_2.9.3/Tests/case.SF-929151.stable.out b/sql/test/BugDay_2005-10-06_2.9.3/Tests/case.SF-929151.stable.out
--- a/sql/test/BugDay_2005-10-06_2.9.3/Tests/case.SF-929151.stable.out
+++ b/sql/test/BugDay_2005-10-06_2.9.3/Tests/case.SF-929151.stable.out
@@ -31,7 +31,7 @@ Ready.
[ 1 ]
% sys. # table_name
% ifthenelse_isnull_=_i # name
-% char # type
+% varchar # type
% 23 # length
[ "base table" ]
[ "system table" ]
diff --git a/sql/test/BugDay_2005-10-06_2.9.3/Tests/jdbc_crashes_on_getTables.SF_944316.stable.out b/sql/test/BugDay_2005-10-06_2.9.3/Tests/jdbc_crashes_on_getTables.SF_944316.stable.out
--- a/sql/test/BugDay_2005-10-06_2.9.3/Tests/jdbc_crashes_on_getTables.SF_944316.stable.out
+++ b/sql/test/BugDay_2005-10-06_2.9.3/Tests/jdbc_crashes_on_getTables.SF_944316.stable.out
@@ -43,8 +43,8 @@ Ready.
#ORDER BY "TABLE_TYPE",
% .tables, .tables, .tables, .tables, .tables, .tables, .tables, .tables, .tables, .tables # table_name
% TABLE_CAT, TABLE_SCHEM, TABLE_NAME, TABLE_TYPE, REMARKS, TYPE_CAT, TYPE_SCHEM, TYPE_NAME, SELF_REFERENCING_COL_NAME, REF_GENERATION # name
-% char, varchar, varchar, char, char, char, char, char, char, char # type
-% 0, 0, 0, 12, 0, 0, 0, 0, 2, 6 # length
+% char, varchar, varchar, varchar, varchar, char, char, char, varchar, varchar # type
+% 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 # length
# 11:50:19 >
# 11:50:19 > Done.
diff --git a/sql/test/BugDay_2005-10-06_2.9.3/Tests/simple_union.SF-1005596.stable.out b/sql/test/BugDay_2005-10-06_2.9.3/Tests/simple_union.SF-1005596.stable.out
--- a/sql/test/BugDay_2005-10-06_2.9.3/Tests/simple_union.SF-1005596.stable.out
+++ b/sql/test/BugDay_2005-10-06_2.9.3/Tests/simple_union.SF-1005596.stable.out
@@ -26,8 +26,8 @@ Ready.
% .tables, .tables, .tables, .tables, .tables, .tables, .tables, .tables, .tables, .tables # table_name
% TABLE_CAT, TABLE_SCHEM, TABLE_NAME, TABLE_TYPE, REMARKS, TYPE_CAT, TYPE_SCHEM, TYPE_NAME, SELF_REFERENCING_COL_NAME, REF_GENERATION # name
-% char, varchar, varchar, char, char, char, char, char, char, char # type
-% 4, 3, 4, 20, 0, 0, 0, 0, 5, 6 # length
+% varchar, varchar, varchar, varchar, varchar, char, char, char, varchar, varchar # type
_______________________________________________
checkin-list mailing list
checkin-list@monetdb.org
http://mail.monetdb.org/mailman/listinfo/checkin-list
_______________________________________________
developers-list mailing list
developers-list@monetdb.org
http://mail.monetdb.org/mailman/listinfo/developers-list