#33815: last_executed_query() incorrectly substitutes parameters on Oracle.
-------------------------------------+-------------------------------------
     Reporter:  Brian                |                    Owner:  nobody
         Type:  Bug                  |                   Status:  new
    Component:  Database layer       |                  Version:  dev
  (models, ORM)                      |
     Severity:  Normal               |               Resolution:
     Keywords:  oracle               |             Triage Stage:  Accepted
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by Mariusz Felisiak):

 * keywords:   => oracle
 * component:  Uncategorized => Database layer (models, ORM)
 * stage:  Unreviewed => Accepted


Comment:

 Thanks for the report. I attached a small regression test:
 {{{#!diff
 diff --git a/tests/backends/tests.py b/tests/backends/tests.py
 index 9303089b51..b3e3f68335 100644
 --- a/tests/backends/tests.py
 +++ b/tests/backends/tests.py
 @@ -101,6 +101,7 @@ class LastExecutedQueryTest(TestCase):
                  pk=1,
                  reporter__pk=9,
              ).exclude(reporter__pk__in=[2, 1]),
 +            Article.objects.filter(pk__in=list(range(20, 31))),
          ):
              sql, params = qs.query.sql_with_params()
              with
 qs.query.get_compiler(DEFAULT_DB_ALIAS).execute_sql(CURSOR) as cursor:
 }}}

-- 
Ticket URL: <https://code.djangoproject.com/ticket/33815#comment:1>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/01070181b0b0cc4d-c162c64d-91c4-42fa-9c61-3c321d18f491-000000%40eu-central-1.amazonses.com.

Reply via email to