Skip to content

Commit

Permalink
Fixed django#2514 -- Improved psycopg2 backend to save/load Unicode s…
Browse files Browse the repository at this point in the history
…trings correctly. Thanks, crankycoder@gmail.com

git-svn-id: http://code.djangoproject.com/svn/django/trunk@3565 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information
adrianholovaty committed Aug 12, 2006
1 parent 9ce3273 commit 9cd0c33
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions AUTHORS
Expand Up @@ -60,6 +60,7 @@ answer newbie questions, and generally made Django that much better:
Amit Chakradeo <http://amit.chakradeo.net/>
ChaosKCW
Ian Clelland <clelland@gmail.com>
crankycoder@gmail.com
Matt Croydon <http://www.postneo.com/>
Jonathan Daugherty (cygnus) <http://www.cprogrammer.org/>
Jason Davies (Esaj) <http://www.jasondavies.com/>
Expand Down
4 changes: 4 additions & 0 deletions django/db/backends/postgresql_psycopg2/base.py
Expand Up @@ -11,6 +11,10 @@
from django.core.exceptions import ImproperlyConfigured
raise ImproperlyConfigured, "Error loading psycopg2 module: %s" % e

# Register Unicode conversions
import psycopg2.extensions
psycopg2.extensions.register_type(psycopg2.extensions.UNICODE)

DatabaseError = Database.DatabaseError

try:
Expand Down

0 comments on commit 9cd0c33

Please sign in to comment.