Fixing strange postgres error

"PG::InvalidParameterValue: ERROR: new encoding (UTF8) is incompatible
with the encoding of the template database (SQL_ASCII)"