in reply to Can't I chop the lvalue of join?

In the values section of the SQL statement, I need a string of the form "?,?,?" where there is a ? for each field, and all the ?s are delimited by commas.
Just do
join ',', map "?", keys %$c
or
join ',', ("?") x keys %$c
(preferably the latter.)

And no, you can't chop the result of join directly, though your code (at least, the first two lines) works fine, as does this slightly more compacted version:

chop(my $placeholderstr = join '', map {'?,'} keys %$c);
Your immediate problem must lie elsewhere.

p.s. A combination of your and my ideas resulted in

chop(my $placeholderstr = '?,' x keys %$c);
and it works just fine.