]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
- clarify that the pg8000 backend has no impact of any kind on
authorMike Bayer <mike_mp@zzzcomputing.com>
Fri, 4 Jul 2014 19:49:01 +0000 (15:49 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Fri, 4 Jul 2014 19:50:04 +0000 (15:50 -0400)
the pg8000 DBAPI's encoding behavior, fixes #3112.

lib/sqlalchemy/dialects/postgresql/pg8000.py

index 8ed7c9423d7d12fec511a65de2bb198346fef39a..dc5ed6e73f522bd0b1efd07e4f80baca07f29fd3 100644 (file)
@@ -16,14 +16,15 @@ postgresql+pg8000://user:password@host:port/dbname[?key=value&key=value...]
 Unicode
 -------
 
-When communicating with the server, pg8000 uses the character set that the
-server asks it to use (the client encoding). By default the client encoding is
-the database's character set (chosen when the database is created), but the
-client encoding can be changed in a number of ways (eg. setting CLIENT_ENCODING
-in postgresql.conf).
-
-Set the "encoding" parameter on create_engine(), to the same as the client
-encoding, usually "utf-8".
+When communicating with the server, pg8000 **always uses the server-side
+character set**.  SQLAlchemy has no ability to modify what character set
+pg8000 chooses to use, and additionally SQLAlchemy does no unicode conversion
+of any kind with the pg8000 backend. The origin of the client encoding setting
+is ultimately the CLIENT_ENCODING setting in postgresql.conf.
+
+It is not necessary, though is also harmless, to pass the "encoding" parameter
+to :func:`.create_engine` when using pg8000.
+
 
 .. _pg8000_isolation_level: