in reply to Elegant way to turn array of values into SQL "where" clause
Try SQL::Abstract instead, then you won't have to construct that awkward array at all...
use DBI; use SQL::Abstract; my $dbh = DBI->connect("dbi:...."); my $sql = SQL::Abstract->new(); my ( $stmt, @bind ) = $sql->update( 'table', { Y => 0 }, { X => \@ARRAY }, ); my $sth = $dbh->prepare( $stmt ); $sth->execute( @bind );
| We're not surrounded, we're in a target-rich environment! |
|---|
|
|---|