Changes between Version 1 and Version 2 of Ticket #25517


Ignore:
Timestamp:
Oct 6, 2015, 2:04:40 PM (9 years ago)
Author:
Warren Smith
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #25517 – Description

    v1 v2  
    55This problem may not manifest itself in a typical request/response context, as the SQL with the additional `COALESCE()` calls will work identically to the original and the SQL may not be re-generated a sufficient number of times to crash the parser.
    66
    7 However, in a long-running process (where this bug was found), it can be easily triggered. For example, say I have a "base" queryset with a `Concat()` within an `.annotate()`. I never actually evaluate this queryset, but I use it to construct other querysets which I do evaluate. Because all of these querysets share the same instance of Query._annotations, evaluating ANY of these querysets will add an additional level of `COALESCE()` to the SQL generated by the others.
     7However, in a long-running process (where this bug was found), it can be easily triggered. For example, say I have a "base" queryset with a `Concat()` within an `.annotate()`. I never actually evaluate this queryset, but I use it to construct other querysets which I do evaluate. Because all of these querysets share the same instance of `Query._annotations`, evaluating ANY of these querysets will add an additional level of `COALESCE()` to the SQL generated by the others.
    88
    99I have a fix coded. I will submit a PR shortly.
Back to Top