I have a Windows DB2 database that I need to migrate to PostgreSQL 9.4 on RedHat Linux. The database cluster was initialized with locale "en_US.UTF-8".
For my migrated database, I need to create a PostgreSQL database with ENCODING 'WIN1252'. Is it possible to do this on my current cluster? My research seems to indicatate that WIN1252 is a subset of UTF8. But I can't find anything to tell me what to put for the LC_COLLATE or LC_CTYPE options.
I tried the following; CREATE DATABASE :dbName WITH OWNER :dbOwner ENCODING 'WIN1252' CONNECTION LIMIT -1; and got this error: ERROR: encoding "WIN1252" does not match locale "en_US.UTF-8" DETAIL: The chosen LC_CTYPE setting requires encoding "UTF8".
I then tried: CREATE DATABASE :dbName WITH OWNER :dbOwner ENCODING 'WIN1252' LC_COLLATE='en_US.1252' CONNECTION LIMIT -1; but got this error: ERROR: invalid locale name: "en_US.1252"
And tried: CREATE DATABASE :dbName WITH OWNER :dbOwner ENCODING 'WIN1252' LC_COLLATE='en_US.WIN1252' CONNECTION LIMIT -1; and got this: ERROR: invalid locale name: "en_US.WIN1252"
Any help would be greatly appreciated. Thanks, Karin Hilbert