uzeuze
uzeuze

Reputation: 63

Special characters are not encoded on Amazon RDS (PostgreSQL)

I can not see Turkish special characters on Amazon RDS PostgreSQL database. My development database displays characters properly.

When I connect to RDS instance via pgAdmin, I see ■aja²a³a­a@test.com instead of şajaıaüağaç@test.com.

My server encoding and collate are UTF8 and en_US.UTF-8, respectively.

In database.yml file I set encoding to utf8.

default: &default
  adapter: postgresql
  encoding: utf8

There isn't any problem on my development database which is also PostgreSQL.

What am I doing wrong?

Upvotes: 0

Views: 2030

Answers (1)

Uzbekjon
Uzbekjon

Reputation: 11813

As far as I can remember, AWS RDS creates databases in latin1 encoding by default. Make sure your DB's and created tables' encoding is set to utf-8.

Upvotes: 1

Related Questions