1
by brian
clean slate |
1 |
#
|
2 |
# Test metadata
|
|
3 |
#
|
|
4 |
||
5 |
--disable_warnings |
|
6 |
drop table if exists t1,t2; |
|
7 |
--enable_warnings |
|
8 |
--enable_metadata |
|
9 |
||
10 |
#
|
|
11 |
# First some simple tests
|
|
12 |
#
|
|
13 |
||
14 |
select 1, 1.0, -1, "hello", NULL; |
|
15 |
||
685.4.3
by Jay Pipes
Fixed metadata.test. Only some minor SQL syntax changes, removal of VIEW stuff from the test, and verifying the old differences in the result file were due to our column type being different. |
16 |
create table t1 (a int, b int, c int, d int, e bigint, f float(3,2), g double(4,3), h decimal(5,4), j date, k timestamp, l datetime, m enum('a','b'), n char(10)); |
1
by brian
clean slate |
17 |
select * from t1; |
18 |
select a b, b c from t1 as t2; |
|
19 |
drop table t1; |
|
20 |
||
21 |
#
|
|
22 |
# Test metadata from ORDER BY (Bug #2654)
|
|
23 |
#
|
|
24 |
||
685.4.3
by Jay Pipes
Fixed metadata.test. Only some minor SQL syntax changes, removal of VIEW stuff from the test, and verifying the old differences in the result file were due to our column type being different. |
25 |
CREATE TABLE t1 (id int default NULL, data varchar(255) default NULL); |
1
by brian
clean slate |
26 |
INSERT INTO t1 VALUES (1,'male'),(2,'female'); |
685.4.3
by Jay Pipes
Fixed metadata.test. Only some minor SQL syntax changes, removal of VIEW stuff from the test, and verifying the old differences in the result file were due to our column type being different. |
27 |
CREATE TABLE t2 (id int default NULL, data char(3) default '0'); |
1
by brian
clean slate |
28 |
INSERT INTO t2 VALUES (1,'yes'),(2,'no'); |
29 |
||
30 |
select t1.id, t1.data, t2.data from t1, t2 where t1.id = t2.id; |
|
31 |
select t1.id, t1.data, t2.data from t1, t2 where t1.id = t2.id order by t1.id; |
|
32 |
select t1.id from t1 union select t2.id from t2; |
|
33 |
drop table t1,t2; |
|
34 |
||
35 |
#
|
|
36 |
# variables union and derived tables metadata test
|
|
37 |
#
|
|
38 |
create table t1 ( a int, b varchar(30), primary key(a)); |
|
39 |
insert into t1 values (1,'one'); |
|
40 |
insert into t1 values (2,'two'); |
|
41 |
set @arg00=1 ; |
|
42 |
select @arg00 FROM t1 where a=1 union distinct select 1 FROM t1 where a=1; |
|
43 |
select * from (select @arg00) aaa; |
|
44 |
select 1 union select 1; |
|
45 |
select * from (select 1 union select 1) aaa; |
|
46 |
drop table t1; |
|
47 |
||
48 |
--disable_metadata |
|
49 |
||
50 |
#
|
|
51 |
# Bug #11688: Bad mysql_info() results in multi-results
|
|
52 |
#
|
|
928.1.8
by Eric Day
All tests now passing now, fixed a few more client utility bugs. |
53 |
# No multi-statements in Drizzle
|
54 |
#
|
|
55 |
#--enable_info
|
|
56 |
#delimiter //;
|
|
57 |
#create table t1 (i int);
|
|
58 |
#insert into t1 values (1),(2),(3);
|
|
59 |
#select * from t1 where i = 2;
|
|
60 |
#drop table t1;//
|
|
61 |
#delimiter ;//
|
|
62 |
#--disable_info
|
|
1
by brian
clean slate |
63 |
|
64 |
# End of 4.1 tests
|
|
65 |
||
66 |
#
|
|
67 |
# Bug #28492: subselect returns LONG in >5.0.24a and LONGLONG in <=5.0.24a
|
|
68 |
#
|
|
69 |
--enable_metadata |
|
70 |
select a.* from (select 2147483648 as v_large) a; |
|
71 |
select a.* from (select 214748364 as v_small) a; |
|
72 |
--disable_metadata |
|
73 |
||
74 |
--echo End of 5.0 tests |