mnlight has asked for the wisdom of the Perl Monks concerning the following question:
sub get_stripe_count() { my ( $dbh, $DB ) = @_; my $stripes = 0; my $size = 0; my $stripe_size = 1000; my $max_stripes = 32; my $sql = "execute sp_dbsize $DB"; my $sth = $$dbh->prepare($sql) or $app->error($FATAL, "Can't do SQL statement [ $sql ] :: $DBI +::errstr"); $sth->execute() or $app->error($FATAL,"Can't execute SQL statement [ $sql ] :: +$DBI::errstr"); $size = $sth->fetchrow_array(); $sth->finish(); $$dbh->disconnect();
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Can't execute sql
by mpeppler (Vicar) on Jan 28, 2003 at 21:26 UTC | |
|
Re: Can't execute sql
by ibanix (Hermit) on Jan 28, 2003 at 19:18 UTC | |
by mnlight (Scribe) on Jan 28, 2003 at 19:33 UTC | |
by ibanix (Hermit) on Jan 28, 2003 at 19:36 UTC | |
by steves (Curate) on Jan 28, 2003 at 19:57 UTC | |
by mnlight (Scribe) on Jan 28, 2003 at 20:15 UTC | |
|
Re: Can't execute sql
by poj (Abbot) on Jan 28, 2003 at 20:11 UTC | |
|
Re: Can't execute sql
by steves (Curate) on Jan 28, 2003 at 19:37 UTC | |
|
Re: Can't execute sql
by rdfield (Priest) on Jan 29, 2003 at 09:53 UTC |