Changes between Initial Version and Version 2 of Ticket #20127


Ignore:
Timestamp:
Oct 8, 2015, 6:22:14 PM (9 years ago)
Author:
Tim Graham
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #20127

    • Property Triage Stage UnreviewedAccepted
  • Ticket #20127 – Description

    initial v2  
    1 There are some different ways for doing subqueries in the ORM currently. Query.split_exclude(), subqueries in deletion, as_nested_sql() and SubqueryConstraint seem to do something similar. Sometimes there are duplicated code paths, sometimes upper layers do something the lower layers will repeat later on.
     1There are some different ways for doing subqueries in the ORM currently. `Query.split_exclude()`, subqueries in deletion, `as_nested_sql()` and `SubqueryConstraint` seem to do something similar. Sometimes there are duplicated code paths, sometimes upper layers do something the lower layers will repeat later on.
    22
    3 I think every instance where a subquery constrain is needed should use the SubqueryConstraint either directly, or through QuerySet.filter() or sql.Query.build_filter(). This will allow doing all the somewhat complicated setup in one place.
     3I think every instance where a subquery constraint is needed should use the `SubqueryConstraint` class either directly, or through `QuerySet.filter()` or `sql.Query.build_filter()`. This will allow doing all the somewhat complicated setup in one place.
Back to Top