in reply to DBI trace and Apache
Maybe it is your version of DBI on that machine?
You can output that by using
print "Installed DB driver versions, and DBI version:\n"; DBI->installed_versions;
This will output something like:
Perl : 5.028001 (x86_64-linux-gnu-thread-multi) OS : linux (4.9.0) DBI : 1.642 DBD::Sponge : 12.010003 DBD::SQLite : 1.64 DBD::Proxy : install_driver(Proxy) failed: Can't locate RPC/PlC +lient.pm in @INC (you may need to install the RPC::PlClient module) DBD::Mem : 0.001 DBD::Gofer : 0.015327 DBD::File : 0.44 DBD::ExampleP : 12.014311 DBD::DBM : 0.08
Alternatively, you can hook into the execution of SQL statements and output them yourself (if the version of DBI is recent enough):
sub dbh_install( $self, $dbh ) { my $previous_handler = $dbh->{HandleError}; $dbh->{Callbacks} = { prepare => sub { my ($dbh, $query, $attrs) = @_; print "Preparing q{$query}\n" }, execute => sub { print "Executing ", shift->{Statement}, "\n"; } }; }
|
|---|