summaryrefslogtreecommitdiff
path: root/django/db/backends/postgresql_psycopg2/operations.py
diff options
context:
space:
mode:
authorJacob Kaplan-Moss <jacob@jacobian.org>2011-04-22 12:14:54 +0000
committerJacob Kaplan-Moss <jacob@jacobian.org>2011-04-22 12:14:54 +0000
commit5b0e4e49d4ab5e976fbfdde70c525a13220f3259 (patch)
tree5e09c9c9eedefb8b0d815c0214afc09b4db76653 /django/db/backends/postgresql_psycopg2/operations.py
parent598032b8c4ec7d642b6223af8569bef81d183385 (diff)
downloaddjango-5b0e4e49d4ab5e976fbfdde70c525a13220f3259.tar.gz
Fixed #14091 - be more correct about logging queries in connection.queries.
Thanks to Aymeric Augustin for figuring out how to make this work across multiple databases. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16081 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django/db/backends/postgresql_psycopg2/operations.py')
-rw-r--r--django/db/backends/postgresql_psycopg2/operations.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/django/db/backends/postgresql_psycopg2/operations.py b/django/db/backends/postgresql_psycopg2/operations.py
index 4efdb8fa3e..33159133d6 100644
--- a/django/db/backends/postgresql_psycopg2/operations.py
+++ b/django/db/backends/postgresql_psycopg2/operations.py
@@ -202,9 +202,8 @@ class DatabaseOperations(BaseDatabaseOperations):
return 63
def last_executed_query(self, cursor, sql, params):
- # With psycopg2, cursor objects have a "query" attribute that is the
- # exact query sent to the database. See docs here:
- # http://www.initd.org/tracker/psycopg/wiki/psycopg2_documentation#postgresql-status-message-and-executed-query
+ # http://initd.org/psycopg/docs/cursor.html#cursor.query
+ # The query attribute is a Psycopg extension to the DB API 2.0.
return cursor.query
def return_insert_id(self):