my @row = $dbh->selectrow_array(q{SELECT my_data1, my_data2 WHERE furniture_type=?},undef, $furniture_type); #### $dbh = DBI->connect($DBDSN, $DBUser, $DBPassword, {RaiseError => 1}); #### my ($furniture_name, $price); chomp($furniture_type); $sth->execute($furniture_type) or die "Couldn't execute: '$DBI::errstr'"; $sth->bind_col(1, \$furniture_name); $sth->bind_col(2, \$price); #### chomp($furniture_type); $sth->execute($furniture_type) or die "Couldn't execute: '$DBI::errstr'"; $sth->bind_columns(\my ($furniture_name, $price));