diff options
| author | Shai Berger <shai@platonix.com> | 2013-06-28 06:15:03 +0300 |
|---|---|---|
| committer | Shai Berger <shai@platonix.com> | 2013-06-28 06:59:10 +0300 |
| commit | d097417025e71286ad5bbde6e0a79caacabbbd64 (patch) | |
| tree | 007c58c8787cee32cf68d08683b7c5294e8a4ad1 /django/db/backends/__init__.py | |
| parent | 7c0b72a826a3637b30a57553ac83f6b913c33134 (diff) | |
Support 'pyformat' style parameters in raw queries, Refs #10070
Add support for Oracle, fix an issue with the repr of RawQuerySet,
add tests and documentations. Also added a 'supports_paramstyle_pyformat'
database feature, True by default, False for SQLite.
Thanks Donald Stufft for review of documentation.
Diffstat (limited to 'django/db/backends/__init__.py')
| -rw-r--r-- | django/db/backends/__init__.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/django/db/backends/__init__.py b/django/db/backends/__init__.py index 1a74232704..9abb9a9637 100644 --- a/django/db/backends/__init__.py +++ b/django/db/backends/__init__.py @@ -613,6 +613,11 @@ class BaseDatabaseFeatures(object): # when autocommit is disabled? http://bugs.python.org/issue8145#msg109965 autocommits_when_autocommit_is_off = False + # Does the backend support 'pyformat' style ("... %(name)s ...", {'name': value}) + # parameter passing? Note this can be provided by the backend even if not + # supported by the Python driver + supports_paramstyle_pyformat = True + def __init__(self, connection): self.connection = connection |
