Casts arguments in find_by_attributes

To ensure the arguments that are passed to find_by_attributes are the same type as the attribute.

This should fix the problem with MySQL2 mentioned here: http://www.phenoelit.org/blog/archives/2013/02/05/mysql_madness_and_rails/index.html

Ideally, this should be somehow fixed in the MySQL2 Adapter or fixed in MySQL.