in reply to Escaping single quotes and DBI

MySQL has a "different" (not to say weird) way to quote quotes (hm, sounds funny, doesn;t it?). Anyways, it workslike this:
'The guy''s house' is "The guy's house" in perl (well, you could write + 'The guy\'s house', too..) "He said ""Hello""" is "He said \"Hello\"" in perl (or, 'He said "Hell +o"')

Knowing that you can use a very simple regexp to quote your comment:
#i assume here that you define $comment somewhere else.. $comment =~ s/"/""/g; # if you use double-quotes # OR: $comment =~ s/'/''/g; # is you use single-quotes

Hope this was of any help for you :)