diff options
author | Michael Widenius <monty@askmonty.org> | 2010-02-09 19:17:04 +0200 |
---|---|---|
committer | Michael Widenius <monty@askmonty.org> | 2010-02-09 19:17:04 +0200 |
commit | d474428c9aef708a4d2af049efcca4886911126f (patch) | |
tree | b6b92a750c09df613ced927c6f77253083302890 /sql-bench/server-cfg.sh | |
parent | 7bd147960606a8c44cbdb9f7b08bba4887a37f18 (diff) | |
download | mariadb-git-d474428c9aef708a4d2af049efcca4886911126f.tar.gz |
Added --connect-command="sql-string" to sql-bench test suite.
This allows one to send an extra command to the mysql server to setup the environment before starting tests.
Diffstat (limited to 'sql-bench/server-cfg.sh')
-rw-r--r-- | sql-bench/server-cfg.sh | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sql-bench/server-cfg.sh b/sql-bench/server-cfg.sh index 5ed7fdf482c..3ff1ce99659 100644 --- a/sql-bench/server-cfg.sh +++ b/sql-bench/server-cfg.sh @@ -249,6 +249,11 @@ sub connect die "Got error: '$DBI::errstr' when connecting to " . $self->{'data_source'} ." with user: '$main::opt_user' password: '$main::opt_password'\n"; $dbh->do("SET OPTION LOG_OFF=1,UPDATE_LOG=0"); + if ($main::opt_connect_command ne "") + { + $dbh->do($main::opt_connect_command) or + die "Can't execute connect_command: $main::opt_connect_command error: $DBI::errstr\n"; + } return $dbh; } |