~ubuntu-branches/ubuntu/trusty/drizzle/trusty

« back to all changes in this revision

Viewing changes to tests/include/loaddata_autocom.inc

  • Committer: Bazaar Package Importer
  • Author(s): Monty Taylor
  • Date: 2010-03-18 12:12:31 UTC
  • Revision ID: james.westby@ubuntu.com-20100318121231-k6g1xe6cshbwa0f8
Tags: upstream-2010.03.1347
ImportĀ upstreamĀ versionĀ 2010.03.1347

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# Test if the engine does autocommit in LOAD DATA INFILE, or not
 
2
# (NDB wants to do, others don't).
 
3
 
 
4
eval SET SESSION STORAGE_ENGINE = $engine_type;
 
5
 
 
6
--disable_warnings
 
7
drop table if exists t1;
 
8
--enable_warnings
 
9
 
 
10
# NDB does not support the create option 'Binlog of table with BLOB attribute and no PK'
 
11
# So use a dummy PK here.
 
12
create table t1 (id int not null auto_increment primary key, a text, b text);
 
13
start transaction;
 
14
load data infile '../std_data_ln/loaddata2.dat' into table t1 fields terminated by ',' enclosed by '''' (a, b);
 
15
commit;
 
16
select count(*) from t1;
 
17
truncate table t1;
 
18
start transaction;
 
19
load data infile '../std_data_ln/loaddata2.dat' into table t1 fields terminated by ',' enclosed by '''' (a, b);
 
20
rollback;
 
21
select count(*) from t1;
 
22
 
 
23
drop table t1;