summaryrefslogtreecommitdiff
path: root/mysql-test/suite/plugins/r/test_sql_service.result
blob: 00f0411b665e68d5dfa71d9dcea6e388ea6fa825 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
install plugin test_sql_service soname 'test_sql_service';
show status like 'test_sql_service_passed';
Variable_name	Value
Test_sql_service_passed	1
set global test_sql_service_run_test= 1;
show status like 'test_sql_service_passed';
Variable_name	Value
Test_sql_service_passed	1
set global test_sql_service_execute_sql_local= 'create table test.t1(id int)';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query affected 0 rows.
set global test_sql_service_execute_sql_local= 'insert into test.t1 values (1), (2)';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query affected 2 rows.
set global test_sql_service_execute_sql_local= 'select * from test.t1';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query returned 2 rows.
set global test_sql_service_execute_sql_local= 'drop table test.t1';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query affected 0 rows.
set global test_sql_service_execute_sql_local= 'drop table test.t1';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Error 1051 returned. Unknown table 'test.t1'
set global test_sql_service_execute_sql_global= 'create table test.t1(id int)';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query affected 0 rows.
set global test_sql_service_execute_sql_global= 'insert into test.t1 values (1), (2)';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query affected 2 rows.
set global test_sql_service_execute_sql_global= 'select * from test.t1';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query returned 2 rows.
set global test_sql_service_execute_sql_global= 'drop table test.t1';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query affected 0 rows.
set global test_sql_service_execute_sql_global= 'drop table test.t1';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Error 1051 returned. Unknown table 'test.t1'
create table t1 (id int, time timestamp);
insert into t1 values (1, NULL), (2, NULL), (3, NULL), (4, NULL), (5, NULL);
set global test_sql_service_execute_sql_global= 'select * FROM test.t1 WHERE time < DATE_SUB(NOW(), interval 5 minute)';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query returned 0 rows.
set global test_sql_service_execute_sql_global= 'select * FROM test.t1 WHERE time <= NOW()';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query returned 5 rows.
set global test_sql_service_execute_sql_local= 'select * FROM test.t1 WHERE time < DATE_SUB(NOW(), interval 5 minute)';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query returned 0 rows.
set global test_sql_service_execute_sql_local= 'select * FROM test.t1 WHERE time <= NOW()';
show status like 'test_sql_query_result';
Variable_name	Value
Test_sql_query_result	Query returned 5 rows.
drop table t1;
uninstall plugin test_sql_service;
Warnings:
Warning	1620	Plugin is busy and will be uninstalled on shutdown