or download this
$sth5 = $dbh->prepare("SELECT round,department,score FROM trees WHERE
+ sport = \'$sport\' AND year = \'$year\' ORDER BY round DESC")|| die
+"couldn't prepareSQL statement";
$sth5->execute || die "can't execute sql statement";
...
$rowcount++;
}