/usr/share/doc/libdbd-odbc-perl/examples/moreresults.pl is in libdbd-odbc-perl 1.56-1.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | #!/usr/bin/perl -w
# $Id$
#
# Sorry -- this test is pretty specific to MSSQL Server and Sybase...
#
use DBI;
my (@row);
my $dbh;
$dbh = DBI->connect()
|| die "Can't connect to your $ENV{DBI_DSN} using user: $ENV{DBI_USER} and pass: $ENV{DBI_PASS}\n$DBI::errstr\n";
# ------------------------------------------------------------
my $result_sets = 0;
$| = 1;
my $sth;
$sth = $dbh->prepare("{call sp_spaceused}")
or die $dbh->errstr;
$sth->execute
or die $sth->errstr;
do {
print join(":", @{$sth->{NAME}}), "\n";
while ( my $ref = $sth->fetch ) {
print join(":", @$ref), "\n";
}
} while ($sth->{odbc_more_results});
print "(", $sth->rows, " rows affected)\n";
$sth->finish;
$dbh->disconnect();
|