Ticket #3721: oracle_lazydate.patch
File oracle_lazydate.patch, 879 bytes (added by , 18 years ago) |
---|
-
django/db/backends/oracle/base.py
77 77 you'll need to use "%%s". 78 78 """ 79 79 def _rewrite_args(self, query, params=None): 80 from django.db.models import LazyDate 80 81 if params is None: 81 82 params = [] 82 83 else: … … 87 88 params[i] = param.encode('utf-8') 88 89 except UnicodeError: 89 90 params[i] = str(param) 91 if type(param) == LazyDate: 92 params[i] = param.__get_value__() 90 93 args = [(':arg%d' % i) for i in range(len(params))] 91 94 query = query % tuple(args) 92 95 # cx_Oracle cannot execute a query with the closing ';'