in reply to Re (2): DBI : select count
in thread DBI : select count

Chris - spot on for the placement of finish()! Exactly the sort of fault that comes from staring at code too long - didn't even see it. Thanks.

Tommy - thanks, but like VSarkiss says above, the quotes make it scope the hash and generates the query properly. But you guys are right about the usefulness of placeholders.