Fix for prepared statement already exists (Postgres)

This PR should fix https://github.com/rails/rails/issues/1627, explanation: https://github.com/rails/rails/issues/1627#issuecomment-62866211
done :)