Commit 6211527f authored by Ian Kelly's avatar Ian Kelly
Browse files

Replaced exact lookups of the empty string with isnull lookups in Oracle. ...

Replaced exact lookups of the empty string with isnull lookups in Oracle.  Fixes the testPreventDuplicateComments case.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@8827 bcc190cf-cafb-0310-a4f2-bffc1f526a37
parent 502fc3ae
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -1050,6 +1050,10 @@ class Query(object):
                raise ValueError("Cannot use None as a query value")
            lookup_type = 'isnull'
            value = True
        elif (value == '' and lookup_type == 'exact' and
              connection.features.interprets_empty_strings_as_nulls):
            lookup_type = 'isnull'
            value = True
        elif callable(value):
            value = value()