| Age | Commit message (Collapse) | Author |
|
subqueries.
691def10a0197d83d2d108bd9043b0916d0f09b4 made all Subquery() instances
equal to each other which broke aggregation subquery pushdown which
relied on object equality to determine which alias it should select.
Subquery.__eq__() will be fixed in an another commit but
Query.rewrite_cols() should haved used object identity from the start.
Refs #30727, #30188.
Thanks Makina Corpus for the report.
Backport of adfbf653dc1c1d0e0dacc4ed46602d22ba28b004 from master
|
|
values()/values_list() after annotate() with aggregations and subqueries.
Subquery annotation references must be resolved if they are excluded
from the GROUP BY clause by a following .values() call.
Regression in fb3f034f1c63160c0ff13c609acd01c18be12f80.
Thanks Makina Corpus for the report.
Backport of 42c08ee46539ef44f8658ebb1cbefb408e0d03fe from master
|
|
against a SimpleLazyObject.
Thanks Simon Charette for the solution and analysis.
Backport of 4237050684427db45ea834fe89d9e11c0520201e from master
|
|
QuerySet.values()/values_list() when they collide with field names.
Regression in fb3f034f1c63160c0ff13c609acd01c18be12f80.
Thanks Holovashchenko Vadym for the report.
Backport of 10866a10fe9f0ad3ffdf6f93823aaf4716e6f27c from master
|
|
selected annotation.
Regression in 0f843fdd5b9b2f2307148465cd60f4e1b2befbb4.
Backport of 59b4e99dd00b9c36d56055b889f96885995e4240 from master
|
|
QuerySet.values()/values_list().
Regression in fb3f034f1c63160c0ff13c609acd01c18be12f80.
Thanks Sigurd Ljødal for the report.
Backport of 0f843fdd5b9b2f2307148465cd60f4e1b2befbb4 from master
|
|
Clearing the SELECT clause in Query.has_results was orphaning GROUP BY
references to it.
Thanks Thierry Bastian for the report and Baptiste Mispelon for the
bisect.
Regression in fb3f034f1c63160c0ff13c609acd01c18be12f80.
Backport of 720de4d0441fcfdb543051389c70efbe66ed962a from master
|
|
BY on aggregations.
Thanks Johannes Hoppe for the report.
Regression in fb3f034f1c63160c0ff13c609acd01c18be12f80.
Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
Backport of 5a4d7285bd10bd40d9f7e574a7c421eb21094858 from master
|
|
conditions outside of queryset filters.
Regression in 4edad1ddf6203326e0be4bdb105beecb0fe454c4.
Thanks utapyngo for the report.
Backport of bf12273db4e53779546e2ac7b65c0ce8e3c8a640 from master.
|
|
list values to tuples.
Regression in 8a281aa7fe76a9da2284f943964a9413697cff1f.
Backport of 8be79984dce7d819879a6e594ca69c5f95a08378 from master
|
|
on chaining.
Thanks Darren Maki for the report.
Backport of 37f8f293775d0b672da8ae369d9a4e17f1db7851 from master
|
|
OuterRef right hand sides have to be nested, just like F rhs have to,
during the subquery pushdown split_exclude performs to ensure they are
resolved against the outer query aliases.
|
|
This allows using expressions that have an output_field that is a
BooleanField to be used directly in a queryset filters, or in the
When() clauses of a Case() expression.
Thanks Josh Smeaton, Tim Graham, Simon Charette, Mariusz Felisiak, and
Adam Johnson for reviews.
Co-Authored-By: NyanKiyoshi <hello@vanille.bid>
|
|
|
|
source expressions is not filterable.
|
|
Previously, we used Query.can_filter() mainly to check if a query is
sliced what was confusing.
|
|
on joined fields.
Co-Authored-By: Simon Charette <charette.s@gmail.com>
|
|
QuerySet.values()/values_list() and order_by() on combined querysets.
|
|
Using annotated FilteredRelations raised a FieldError when coupled with
exclude(). This is due to not passing filtered relation fields to the
subquery created in split_exclude(). We fixed this issue by passing the
filtered relation data to the newly created subquery.
Secondly, in the case where an INNER JOIN is used in the excluded
subquery, the ORM would trim the filtered relation INNER JOIN in attempt
to simplify the query. This will also remove the ON clause filters
generated by the FilteredRelation. We added logic to not trim the INNER
JOIN if it is from FilteredRelation.
|
|
condition on Oracle and SQLite.
|
|
subquery errors.
RecursionError was introduced in Python 3.5 and subclasses RuntimeError.
|
|
sys.getrecursionlimit().
This makes sure the test_avoid_infinite_loop_on_too_many_subqueries test
doesn't fail on systems with a non-default recursion limit.
|
|
Thanks Jan Baryła for the detailed report and the reduced test case.
|
|
|
|
Thanks Can Sarıgöl for the suggested trimming approach.
|
|
|
|
|
|
After 3a505c70e7b228bf1212c067a8f38271ca86ce09, all _prepare() methods
return self.
|
|
|
|
This makes Subquery a thin wrapper over Query and makes sure it respects
the Expression source expression API by accepting the same number of
expressions as it returns. Refs #30188.
It also makes OuterRef usable in Query without Subquery wrapping. This
should allow Query's internals to more easily perform subquery push downs
during split_exclude(). Refs #21703.
|
|
|
|
Partially reverted 50b8493581fea3d7137dd8db33bac7008868d23a (refs #29654)
to avoid a crash when the user shell doesn't support non-ASCII characters.
|
|
Dicts preserve order since Python 3.6.
|
|
|
|
Removed DatabaseIntrospection.table_name_converter()/column_name_converter()
and use instead DatabaseIntrospection.identifier_converter().
Removed DatabaseFeatures.uppercases_column_names.
Thanks Tim Graham for the initial patch and review and Simon Charette
for the review.
|
|
|
|
|
|
|
|
Regression in 2162f0983de0dfe2178531638ce7ea56f54dd4e7.
|
|
|
|
|
|
|
|
|
|
|
|
null value.
|
|
|
|
warnings.
https://bugs.python.org/issue25988
|
|
Unused since b4492a8ca4a7ae4daa3a6b03c3d7a845fad74931.
|
|
continue statements.
|
|
|