http://www.perlmonks.org?node_id=684438


in reply to Inserting large chunks of data into MySQL

First of all, are you sure this code works? perltidy reports that it parses this way:
... $count = $dbh->do("INSERT INTO ques (...) VALUES (...)", undef, $usernamenow, $txtque, ... ); ...
I think you want single quotes for the SQL statement and placeholders (?) like this:
$count = $dbh->do('INSERT INTO ques (...) VALUES (?,?,?,?,...)', undef, $usernamenow, $txtque, ... );
You use of double quotes and string interpolation (i.e. using $usernamenow inside the double-quoted string) will definitely cause you problems.