summaryrefslogtreecommitdiff
path: root/django/db/backends/oracle/base.py
diff options
context:
space:
mode:
authorIan Kelly <ian.g.kelly@gmail.com>2011-04-18 21:59:20 +0000
committerIan Kelly <ian.g.kelly@gmail.com>2011-04-18 21:59:20 +0000
commitb4c83138e9daa0be301d1f18458609f003d19922 (patch)
tree72acd99c45a55717d3b8a40d0b572c2e625060de /django/db/backends/oracle/base.py
parent487cd1fa23eab0fbf02f0e322152b4b348911cdc (diff)
downloaddjango-b4c83138e9daa0be301d1f18458609f003d19922.tar.gz
Fixed #15534: Made the Oracle runtime test for regex capabilities use the !DatabaseOperations connection instead of grabbing the default connection.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16041 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django/db/backends/oracle/base.py')
-rw-r--r--django/db/backends/oracle/base.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/django/db/backends/oracle/base.py b/django/db/backends/oracle/base.py
index a477c8d974..dc70a1018c 100644
--- a/django/db/backends/oracle/base.py
+++ b/django/db/backends/oracle/base.py
@@ -258,9 +258,8 @@ WHEN (new.%(col_name)s IS NULL)
def regex_lookup(self, lookup_type):
# If regex_lookup is called before it's been initialized, then create
# a cursor to initialize it and recur.
- from django.db import connection
- connection.cursor()
- return connection.ops.regex_lookup(lookup_type)
+ self.connection.cursor()
+ return self.connection.ops.regex_lookup(lookup_type)
def return_insert_id(self):
return "RETURNING %s INTO %%s", (InsertIdVar(),)