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


in reply to Speed up DBD::MySQL Queries

Aside from the above answers, that are pinning down the problem, I would recommend reading Speeding up the DBI.

It will show you how to benchmark and profile your code, in addition to some interesting methods for optimizing DBI usage.