So is it normal that without adding the u' to a string that contains french accents will give the error:
ascii' codec can't decode byte 0xc3 in position 10: ordinal not in range(128) ? Are french characters UTF-8 Compliant? Would this insertion process not fail if the data contained within the postgres.sql file contain non UTF-8 characters when mandala4 in this case is UTF-8 encoded? psql mandala4 -U postgres < mandala.postgres.sql Password for user postgres: SET SET SET SET SET CREATE EXTENSION COMMENT SET SET SET CREATE TABLE ALTER TABLE CREATE SEQUENCE ALTER TABLE ALTER SEQUENCE CREATE TABLE ALTER TABLE CREATE SEQUENCE ALTER TABLE ALTER SEQUENCE CREATE TABLE ALTER TABLE CREATE SEQUENCE ALTER TABLE ALTER SEQUENCE CREATE TABLE .... Seeing as it had no problems inserting the french accents into a UTF-8 encoded database, this means that french characters are UTF-8 complaint? This shows you the database is utf8: Name | Owner | Encoding | Collate | Ctype | Access privileg es -----------+----------+----------+-------------+-------------+------------------ ----- mandala | postgres | UTF8 | en_US.UTF-8 | en_US.UTF-8 | mandala3 | postgres | LATIN1 | C | C | * mandala4 | mandala | UTF8 | en_US.UTF-8 | en_US.UTF-8 | * postgres | postgres | UTF8 | en_US.UTF-8 | en_US.UTF-8 | template0 | postgres | UTF8 | en_US.UTF-8 | en_US.UTF-8 | =c/postgres + | | | | | postgres=CTc/post gres template1 | postgres | UTF8 | en_US.UTF-8 | en_US.UTF-8 | =c/postgres + | | | | | postgres=CTc/post gres (6 rows) Here are some snippets from the sql dump file , client encoding is LATIN1 but going into a UTF-8 database, and it did so without issue: SET statement_timeout = 0; SET client_encoding = 'LATIN1'; SET standard_conforming_strings = on; SET check_function_bodies = false; SET client_min_messages = warning; -- -- Name: plpgsql; Type: EXTENSION; Schema: -; Owner: -- CREATE EXTENSION IF NOT EXISTS plpgsql WITH SCHEMA pg_catalog; -- -- Name: EXTENSION plpgsql; Type: COMMENT; Schema: -; Owner: -- COMMENT ON EXTENSION plpgsql IS 'PL/pgSQL procedural language'; SET search_path = public, pg_catalog; SET default_tablespace = ''; SET default_with_oids = false; The auth_user creation as created by django using postgres, but now the login is case sensitive: CREATE TABLE auth_user ( id integer NOT NULL, password character varying(128) NOT NULL, last_login timestamp with time zone NOT NULL, is_superuser boolean NOT NULL, username character varying(30) NOT NULL, first_name character varying(30) NOT NULL, last_name character varying(30) NOT NULL, email character varying(75) NOT NULL, is_staff boolean NOT NULL, is_active boolean NOT NULL, date_joined timestamp with time zone NOT NULL ); example data going in: COPY auth_user (id, password, last_login, is_superuser, username, first_name, last_name, email, is_staff, is_active, date_joined) FROM stdin; 1 bcrypt$$2a$12$YW6Gxsl0z4/PgQPrbwZgm.f5tB2Bnu.wShpNg2rmsr4H3W8knbZsq 2013-08-21 22:07:57.359359-04 t admin a...@a.com t t 2013-08-21 18:16:30-04 Here is the other model with issues when the city has an accent: CREATE TABLE locations_location ( id character varying(20) NOT NULL, created timestamp with time zone, modified timestamp with time zone, address character varying(255), address2 character varying(255), city character varying(255), province character varying(255), postal_code character varying(255), county character varying(255), country character varying(255), phone character varying(255), latitude numeric(11,7), longitude numeric(11,7), open_time time without time zone, close_time time without time zone, is_24_hours boolean NOT NULL, notes text, ); And here is the insert of data and the city that has the problem: 2012-08-29 08:36:00-04 2013-07-16 14:23:00-04 t t t 74 Principale St \N * NĂ©guac* New Brunswick Is this enough info to come up with a good conclusion of what this could be? -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this group, send email to django-users@googlegroups.com. Visit this group at http://groups.google.com/group/django-users. For more options, visit https://groups.google.com/groups/opt_out.