Mysql2 prepared statements bind substitution fix

The placeholders have to be replaced with the actual values when creating the SQL.