Skip to content

Commit

Permalink
Fixed last_executed_query test failure on Oracle
Browse files Browse the repository at this point in the history
  • Loading branch information
shaib committed Jul 8, 2013
1 parent dab9217 commit c0a4894
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion django/db/backends/oracle/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ def last_executed_query(self, cursor, sql, params):
# http://cx-oracle.sourceforge.net/html/cursor.html#Cursor.statement
# The DB API definition does not define this attribute.
statement = cursor.statement
if not six.PY3 and not isinstance(statement, unicode):
if statement and not six.PY3 and not isinstance(statement, unicode):
statement = statement.decode('utf-8')
# Unlike Psycopg's `query` and MySQLdb`'s `_last_executed`, CxOracle's
# `statement` doesn't contain the query parameters. refs #20010.
Expand Down

0 comments on commit c0a4894

Please sign in to comment.