in reply to how do i construct a sql select statement, where i want to get the where clauses out of an array
The first is to do:
The other is to put the ID's into a temp table and join on the temp table.my $ids_in = join ", ", @in; my $sql = "select id, size from table where id in ($ids_in)";
UPDATE
Forgot some silly parens. Thanks runrig.
|
|---|