Changeset: 4c999d6e4f8a for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=4c999d6e4f8a
Modified Files:
        
sql/test/BugTracker-2019/Tests/correlated-subquery-aggregation.Bug-6714.sql
        
sql/test/BugTracker-2019/Tests/correlated-subquery-aggregation.Bug-6714.stable.out
Branch: Apr2019
Log Message:

Re-worked bug 6714 test.

Don't use system tables in tests, as their contents change overtime. These 
changes require to re-approve tests again.


diffs (103 lines):

diff --git 
a/sql/test/BugTracker-2019/Tests/correlated-subquery-aggregation.Bug-6714.sql 
b/sql/test/BugTracker-2019/Tests/correlated-subquery-aggregation.Bug-6714.sql
--- 
a/sql/test/BugTracker-2019/Tests/correlated-subquery-aggregation.Bug-6714.sql
+++ 
b/sql/test/BugTracker-2019/Tests/correlated-subquery-aggregation.Bug-6714.sql
@@ -1,2 +1,37 @@
-select func_id, (select name from functions f where f.id = func_id) as name, 
max(number), count(*) from args
+start transaction;
+create table functions_test(id int, name varchar(64));
+create table args_test(id int, func_id int, name varchar(64), number int);
+insert into functions_test values (1495, 'copyfrom'), (6743, 
'querylog_calls'), (6802, 'tracelog'), (7234, 'bbp'),
+                                  (1, 'dummy');
+COPY 27 RECORDS INTO args_test FROM STDIN NULL AS '';
+6393|1495|res_0|0|
+6394|1495|arg_1|1|
+6395|1495|arg_2|2|
+6396|1495|arg_3|3|
+6744|6743|id|0|
+6745|6743|start|1|
+6746|6743|stop|2|
+6747|6743|arguments|3|
+6748|6743|tuples|4|
+6749|6743|run|5|
+6750|6743|ship|6|
+6751|6743|cpu|7|
+6752|6743|io|8|
+6803|6802|event|0|
+6804|6802|clk|1|
+6805|6802|pc|2|
+6806|6802|thread|3|
+6807|6802|ticks|4|
+6808|6802|rrsmb|5|
+6809|6802|vmmb|6|
+6810|6802|reads|7|
+6811|6802|writes|8|
+6812|6802|minflt|9|
+6813|6802|majflt|10|
+6814|6802|nvcsw|11|
+6815|6802|stmt|12|
+1|1|dummy|1|
+
+select func_id, (select name from functions_test f where f.id = func_id) as 
name, max(number), count(*) from args_test
 group by func_id having count(*) > 8 order by func_id limit 12;
+rollback;
diff --git 
a/sql/test/BugTracker-2019/Tests/correlated-subquery-aggregation.Bug-6714.stable.out
 
b/sql/test/BugTracker-2019/Tests/correlated-subquery-aggregation.Bug-6714.stable.out
--- 
a/sql/test/BugTracker-2019/Tests/correlated-subquery-aggregation.Bug-6714.stable.out
+++ 
b/sql/test/BugTracker-2019/Tests/correlated-subquery-aggregation.Bug-6714.stable.out
@@ -24,20 +24,48 @@ Ready.
 # 16:27:01 >  "mclient" "-lsql" "-ftest" "-tnone" "-Eutf-8" "-i" "-e" 
"--host=/var/tmp/mtest-18731" "--port=37182"
 # 16:27:01 >  
 
-#select func_id, (select name from functions f where f.id = func_id) as name, 
max(number), count(*) from args
-#group by func_id having count(*) > 8 order by func_id limit 12;
-% .args,       .L10,   .L12,   .L14 # table_name
+#start transaction;
+#create table functions_test(id int, name varchar(64));
+#create table args_test(id int, func_id int, name varchar(64), number int);
+#insert into functions_test values (1495, 'copyfrom'), (6743, 
'querylog_calls'), (6802, 'tracelog'), (7234, 'bbp'),
+#                                  (1, 'dummy');
+[ 5    ]
+#COPY 27 RECORDS INTO args_test FROM STDIN NULL AS '';
+#6393|1495|res_0|0|
+#6394|1495|arg_1|1|
+#6395|1495|arg_2|2|
+#6396|1495|arg_3|3|
+#6744|6743|id|0|
+#6745|6743|start|1|
+#6746|6743|stop|2|
+#6747|6743|arguments|3|
+#6748|6743|tuples|4|
+#6749|6743|run|5|
+#6750|6743|ship|6|
+#6751|6743|cpu|7|
+#6752|6743|io|8|
+#6803|6802|event|0|
+#6804|6802|clk|1|
+#6805|6802|pc|2|
+#6806|6802|thread|3|
+#6807|6802|ticks|4|
+#6808|6802|rrsmb|5|
+#6809|6802|vmmb|6|
+#6810|6802|reads|7|
+#6811|6802|writes|8|
+#6812|6802|minflt|9|
+#6813|6802|majflt|10|
+#6814|6802|nvcsw|11|
+[ 27   ]
+#select func_id, (select name from functions_test f where f.id = func_id) as 
name, max(number), count(*) from args_test
+#group by func_id having count(*) > 8 and count(*) < 14 order by func_id limit 
12;
+% .args_test,  .L10,   .L12,   .L14 # table_name
 % func_id,     name,   L12,    L14 # name
 % int, varchar,        int,    bigint # type
 % 4,   14,     2,      2 # length
-[ 1495,        "copyfrom",     12,     13      ]
 [ 6743,        "querylog_calls",       8,      9       ]
 [ 6802,        "tracelog",     12,     13      ]
-[ 7234,        "bbp",  10,     11      ]
-[ 8531,        "storage",      16,     17      ]
-[ 8589,        "storage",      17,     18      ]
-[ 8609,        "storage",      18,     19      ]
-[ 8630,        "storage",      19,     20      ]
+#rollback;
 
 # 16:27:01 >  
 # 16:27:01 >  "Done."
_______________________________________________
checkin-list mailing list
checkin-list@monetdb.org
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to