~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to tests/t/user_var.test

  • Committer: Monty Taylor
  • Date: 2009-03-04 02:16:28 UTC
  • mto: (917.1.2 mordred)
  • mto: This revision was merged to the branch mainline in revision 912.
  • Revision ID: mordred@inaugust.com-20090304021628-rfq0b16uoi09g8tx
Fix to make VPATH builds work again.

Show diffs side-by-side

added added

removed removed

Lines of Context:
81
81
# attributes from values they were initialized to.
82
82
#
83
83
 
84
 
set @a=_latin2'test';
85
 
select charset(@a),collation(@a),coercibility(@a);
86
 
select @a=_latin2'TEST';
87
 
select @a=_latin2'TEST' collate latin2_bin;
 
84
set @a='test';
 
85
select collation(@a),coercibility(@a);
 
86
select @a='TEST';
 
87
select @a='TEST' collate utf8_bin;
88
88
 
89
 
set @a=_latin2'test' collate latin2_general_ci;
90
 
select charset(@a),collation(@a),coercibility(@a);
91
 
select @a=_latin2'TEST';
92
 
select @a=_latin2'TEST' collate latin2_bin;
 
89
set @a='test' collate utf8_general_ci;
 
90
select collation(@a),coercibility(@a);
 
91
select @a='TEST';
 
92
select @a='TEST' collate utf8_bin;
93
93
 
94
94
#
95
95
# Check the same invoking Item_set_user_var
96
96
#
97
 
select charset(@a:=_latin2'test');
98
 
select collation(@a:=_latin2'test');
99
 
select coercibility(@a:=_latin2'test');
100
 
select collation(@a:=_latin2'test' collate latin2_bin);
101
 
select coercibility(@a:=_latin2'test' collate latin2_bin);
102
 
select (@a:=_latin2'test' collate latin2_bin) = _latin2'TEST';
103
 
select charset(@a),collation(@a),coercibility(@a);
104
 
select (@a:=_latin2'test' collate latin2_bin) = _latin2'TEST' collate latin2_general_ci;
 
97
select collation(@a:='test');
 
98
select coercibility(@a:='test');
 
99
select collation(@a:='test' collate utf8_bin);
 
100
select coercibility(@a:='test' collate utf8_bin);
 
101
select (@a:='test' collate utf8_bin) = 'TEST';
 
102
select collation(@a),coercibility(@a);
 
103
select (@a:='test' collate utf8_bin) = 'TEST' collate utf8_general_ci;
105
104
 
106
105
#
107
106
# Bug #6321 strange error:
122
121
#
123
122
--error 1064
124
123
set session @honk=99;
125
 
--error 1382
126
 
set one_shot @honk=99;
127
124
 
128
125
#
129
126
# Bug #10724  @@local not preserved in column name of select
153
150
create table t1 select @first_var;
154
151
show create table t1;
155
152
drop table t1;
156
 
set @first_var= cast(NULL as signed integer);
157
 
create table t1 select @first_var;
158
 
show create table t1;
159
 
drop table t1;
 
153
 
 
154
# This is not supported by Drizzle
 
155
--error 1064
 
156
set @first_var= cast(NULL as integer);
 
157
#create table t1 select @first_var;
 
158
#show create table t1;
 
159
#drop table t1;
 
160
 
160
161
set @first_var= NULL;
161
162
create table t1 select @first_var;
162
163
show create table t1;
190
191
select * from bigfailure where afield = (SELECT afield FROM bigfailure);
191
192
select * from bigfailure where afield = 18446744071710965857;
192
193
# This is fixed in 5.0, to be uncommented there
193
 
#select * from bigfailure where afield = '18446744071710965857';
 
194
select * from bigfailure where afield = '18446744071710965857';
194
195
select * from bigfailure where afield = 18446744071710965856+1;
195
196
 
196
197
SET @a := (SELECT afield FROM bigfailure);
210
211
insert into t1 values (1,2),(2,3),(3,1);
211
212
select @var:=f2 from t1 group by f1 order by f2 desc limit 1;
212
213
select @var;
213
 
create table t2 as select @var:=f2 from t1 group by f1 order by f2 desc limit 1;
214
 
select * from t2;
215
 
select @var;
216
 
drop table t1,t2;
 
214
# Bug 310977, uncomment this test after the bug is fixed
 
215
#create table t2 as select @var:=f2 from t1 group by f1 order by f2 desc limit 1;
 
216
#select * from t2;
 
217
#select @var;
 
218
drop table t1;
 
219
#drop table t2;
217
220
 
218
221
#
219
222
# Bug#19024 - SHOW COUNT(*) WARNINGS not return Errors