~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to tests/t/update.test

  • Committer: Jay Pipes
  • Date: 2010-03-09 20:02:29 UTC
  • mto: This revision was merged to the branch mainline in revision 1339.
  • Revision ID: jpipes@serialcoder-20100309200229-dfrliy4fads9vyf4
Fixes Bug #535296 by only incrementing ha_commit_count when its a normal transaction commit.

Show diffs side-by-side

added added

removed removed

Lines of Context:
13
13
 
14
14
# Some strange updates to test some otherwise unused code
15
15
update t1 set a=a+100 where a=1 and a=2;
16
 
--error ER_BAD_FIELD_ERROR
 
16
--error 1054
17
17
update t1 set a=b+100 where a=1 and a=2; 
18
 
--error ER_BAD_FIELD_ERROR
 
18
--error 1054
19
19
update t1 set a=b+100 where c=1 and a=2; 
20
 
--error ER_BAD_FIELD_ERROR
 
20
--error 1054
21
21
update t1 set d=a+100 where a=1;
22
22
select * from t1;
23
23
drop table t1;
51
51
  client varchar(255) NOT NULL default '',
52
52
  replyto varchar(255) NOT NULL default '',
53
53
  subject varchar(100) NOT NULL default '',
54
 
  timestamp_arg int NOT NULL default '0',
 
54
  timestamp int NOT NULL default '0',
55
55
  tstamp timestamp NOT NULL,
56
56
  status int NOT NULL default '0',
57
57
  type varchar(15) NOT NULL default '',
66
66
  comment text,
67
67
  header text,
68
68
  PRIMARY KEY  (lfdnr),
69
 
  KEY k1 (timestamp_arg),
 
69
  KEY k1 (timestamp),
70
70
  KEY k2 (type),
71
71
  KEY k3 (parent),
72
72
  KEY k4 (assignment),
152
152
#
153
153
create table t1(f1 int);
154
154
select DATABASE();
155
 
--error ER_INVALID_GROUP_FUNC_USE
 
155
--error 1111
156
156
update t1 set f1=1 where count(*)=1;
157
157
select DATABASE();
158
 
--error ER_INVALID_GROUP_FUNC_USE
 
158
--error 1111
159
159
delete from t1 where count(*)=1;
160
160
drop table t1;
161
161
 
214
214
create table t1 (a int);
215
215
insert into t1 values (0),(1),(2),(3),(4),(5),(6),(7),(8),(9);
216
216
create table t2 (a int, filler1 char(200), filler2 char(200), key(a));
217
 
insert into t2 select A.a + 10*B.a, 'filler','filler' from t1 A CROSS JOIN t1 B;
 
217
insert into t2 select A.a + 10*B.a, 'filler','filler' from t1 A, t1 B;
218
218
flush status;
219
219
update t2 set a=3 where a=2;
220
220
--replace_column 2 #
233
233
# Bug#25126: Wrongly resolved field leads to a crash
234
234
#
235
235
create table t1(f1 int);
236
 
--error ER_BAD_FIELD_ERROR
 
236
--error 1054
237
237
update t1 set f2=1 order by f2;
238
238
drop table t1;
239
239
# End of 4.1 tests
356
356
connection default;
357
357
disconnect con1;
358
358
 
359
 
drop table t1;
360
359
--echo End of 5.0 tests