summaryrefslogtreecommitdiff
path: root/sql-bench/test-wisconsin.sh
diff options
context:
space:
mode:
authorunknown <monty@hundin.mysql.fi>2001-11-08 15:54:22 +0200
committerunknown <monty@hundin.mysql.fi>2001-11-08 15:54:22 +0200
commit40bfbe0bfaaa1bedf9dd7ff5fdcb836eb102911d (patch)
treef041c20e4bea9553dbfec4de709b72029a800b95 /sql-bench/test-wisconsin.sh
parent897e7453d6c669f7460a242a81b874bd0302007b (diff)
downloadmariadb-git-40bfbe0bfaaa1bedf9dd7ff5fdcb836eb102911d.tar.gz
--fast now does all insert/update loops in one transactions
Diffstat (limited to 'sql-bench/test-wisconsin.sh')
-rw-r--r--sql-bench/test-wisconsin.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/sql-bench/test-wisconsin.sh b/sql-bench/test-wisconsin.sh
index 84d098ca583..e7e3a0f235a 100644
--- a/sql-bench/test-wisconsin.sh
+++ b/sql-bench/test-wisconsin.sh
@@ -109,6 +109,11 @@ if ($opt_fast && $server->{'limits'}->{'load_data_infile'})
}
else
{
+ if ($opt_fast && $server->{transactions})
+ {
+ $dbh->{AutoCommit} = 0;
+ }
+
for ($ti = 0; $ti <= $#table_names; $ti++)
{
my $table_name = $table_names[$ti];
@@ -133,10 +138,17 @@ else
}
close(DATA);
}
+
if ($opt_lock_tables)
{
do_query($dbh,"UNLOCK TABLES");
}
+if ($opt_fast && $server->{transactions})
+{
+ $dbh->commit;
+ $dbh->{AutoCommit} = 1;
+}
+
$end_time=new Benchmark;
print "Time to insert ($row_count): " .
timestr(timediff($end_time, $loop_time),"all") . "\n";