in reply to
input compare
http://dev.mysql.com/doc/mysql/en/application-password-use.html
gives some hints on this topic (assuming you use different versions of mysql).
Comment on
Re: input compare
In Section
Seekers of Perl Wisdom