|
|
|
$dbh = DBI->connect($db_source, $db_user, $db_pswd)
or die "connect() failed: " . $DBI::errstr;
$sth = $dbh->prepare($sql)
or die "prepare() failed: " . $DBI::errstr;
$sth->execute()
or die "execute() failed: " . $DBI::errstr;
while(my($num, $name) = $sth->fetchrow_array) {
...
} |
|
|
|
|