diff options
author | unknown <monty@work.mysql.com> | 2001-06-12 14:12:35 +0200 |
---|---|---|
committer | unknown <monty@work.mysql.com> | 2001-06-12 14:12:35 +0200 |
commit | a9e6b975fcf37c491870b3bf18493d0351ffc34f (patch) | |
tree | a5f1c279fea2101ed23cc2fffa79f3517349aff2 /sql-bench/server-cfg.sh | |
parent | 64dc74a13d17b863f0ed69b4f7d621b1b5da48ce (diff) | |
parent | cdcc56705c89909a4077008640aebc894504e99d (diff) | |
download | mariadb-git-a9e6b975fcf37c491870b3bf18493d0351ffc34f.tar.gz |
merge
BitKeeper/etc/ignore:
auto-union
BitKeeper/etc/logging_ok:
auto-union
sql-bench/server-cfg.sh:
Auto merged
sql/sql_base.cc:
Auto merged
sql/sql_insert.cc:
Auto merged
sql/sql_table.cc:
Auto merged
Diffstat (limited to 'sql-bench/server-cfg.sh')
-rw-r--r-- | sql-bench/server-cfg.sh | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/sql-bench/server-cfg.sh b/sql-bench/server-cfg.sh index e43548d924e..8c290a634f7 100644 --- a/sql-bench/server-cfg.sh +++ b/sql-bench/server-cfg.sh @@ -800,18 +800,29 @@ sub reconnect_on_errors sub vacuum { - my ($self,$full_vacuum,$dbh_ref)=@_; - my ($loop_time,$end_time,$dbh); + my ($self,$full_vacuum,$dbh_ref,@tables)=@_; + my ($loop_time,$end_time,$dbh,$table); if (defined($full_vacuum)) { $$dbh_ref->disconnect; $$dbh_ref= $self->connect(); } $dbh=$$dbh_ref; $loop_time=new Benchmark; - $dbh->do("vacuum") || die "Got error: $DBI::errstr when executing 'vacuum'\n"; - $dbh->do("vacuum pg_attributes") || die "Got error: $DBI::errstr when executing 'vacuum'\n"; - $dbh->do("vacuum pg_index") || die "Got error: $DBI::errstr when executing 'vacuum'\n"; - $dbh->do("vacuum analyze") || die "Got error: $DBI::errstr when executing 'vacuum'\n"; + if ($#tables >= 0) + { + foreach $table (@tables) + { + $dbh->do("vacuum analyze $table") || die "Got error: $DBI::errstr when executing 'vacuum analyze $table'\n"; + $dbh->do("vacuum $table") || die "Got error: $DBI::errstr when executing 'vacuum'\n"; + } + } + else + { +# $dbh->do("vacuum pg_attributes") || die "Got error: $DBI::errstr when executing 'vacuum'\n"; +# $dbh->do("vacuum pg_index") || die "Got error: $DBI::errstr when executing 'vacuum'\n"; + $dbh->do("vacuum analyze") || die "Got error: $DBI::errstr when executing 'vacuum analyze'\n"; + $dbh->do("vacuum") || die "Got error: $DBI::errstr when executing 'vacuum'\n"; + } $end_time=new Benchmark; print "Time for book-keeping (1): " . Benchmark::timestr(Benchmark::timediff($end_time, $loop_time),"all") . "\n\n"; |