That's just completely useless. I would suggest you use placeholders and/or the $dbh->quote method - or a nice abstraction layer like
DBIx::Class - that way you don't have to scan your input for anything.
Attempting to catch malicious input is misguided in most cases. You should either only allow known good - verifiable - input or make sure the content of the input doesn't matter.
update:
I think there is room for a Perl module that can screen against all attacks through stored procedures of any database app.
And the problem with that is that you won't know about all potential attacks. Besides that I suspect the code to detect all known attacks would soon be orders of magnitudes larger than the code it's supposed to protect - with all the potential for bugs in and/or security holes caused by the scanning code.