• Rob's avatar
    Fixed #30349 -- Fixed QuerySet.exclude() on FilteredRelation. · 6b736dd0
    Rob yazdı
    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.
    6b736dd0
Adı
Son kayıt (commit)
Son güncelleme
..
__init__.py Loading commit data...
models.py Loading commit data...
tests.py Loading commit data...