~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/transaction_log/tests/t/no_modification.inc

  • Committer: Brian Aker
  • Date: 2009-12-18 18:51:03 UTC
  • mfrom: (1143.4.23 transaction_log)
  • Revision ID: brian@gaz-20091218185103-pc5fo3n9xmd0b503
Merge Jay

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
2
2
# Simple test of the transaction log for when a START TRANSACTION ... COMMIT
3
 
# is issued, but no data modifications actually occurred.
 
3
# is issued, but no data modifications actually occurred. Also tested is
 
4
# a update that does not update anything. 
4
5
5
6
# This situation occurs in, for instance, sysbench, which wraps even SELECTs
6
7
# in a transaction.
11
12
--enable_warnings
12
13
 
13
14
CREATE TABLE t1 (
14
 
  id INT NOT NULL
 
15
  id INT NOT NULL PRIMARY KEY
15
16
, padding VARCHAR(200) NOT NULL
16
17
);
17
18
 
18
19
INSERT INTO t1 VALUES (1, "I love testing.");
19
20
INSERT INTO t1 VALUES (2, "I hate testing.");
20
21
 
 
22
UPDATE t1 SET id=1 WHERE padding='I love testing.';
 
23
 
21
24
START TRANSACTION;
22
25
 
23
26
SELECT * FROM t1 WHERE id = 1;