- or download this
$sth = $dbh->prepare("SELECT year from trees WHERE sport = \'$sport\'
+AND year = + \'$year\'")
|| die "couldn't prepareSQL statement";
...
while (@row = $sth->fetchrow_array()) {
$year = $row[0];
}
- or download this
$sth = $dbh->prepare('SELECT year
FROM trees
...
AND
year = ?'
);
- or download this
$sth->execute($sport, $year) or
die "Can't execute: ". $db->errstr(). "\n";
- or download this
my ($year) = $sth->fetchrow();
- or download this
for (1.. $compsize *2 -1) {
$teams{"team$_"} = $cgi->param("team$_");
$scores{"score$_"} = $cgi->param("score$_");
}
- or download this
print "<ul>\n";
foreach ( $cgi->param) {
print "<li>$_: '", $cgi->param($_) ,"'\n";
}
print "</ul>\n";