A while ago I asked for help on the following:
> I would like to be able to select records from the a table where record_id
> and $record_id from my @record_ids matches. I know I could go through a
loop
> and send a SELECT query for each element in the array but is there a
better
> way? How can I accomplish the same but only sending one query?
One of the responses was the following solution:
@record_ids = param ('record_ids');
....
my $sql = qq{SELECT ad_id, text, life FROM $table WHERE ad_id in(' .
join(',',@record_ids) . ')};
....
then execute the $sql only once
However that doesn't find any records, any obvious mistakes in my sql
statement that you can notice?
thanks a lot,
M
> --
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]