Opened 5 years ago
Closed 5 years ago
#30859 closed Cleanup/optimization (fixed)
Enable the supports_aggregate_filter_clause database feature on SQLite >= 3.30.1
Reported by: | Simon Charette | Owned by: | Mariusz Felisiak |
---|---|---|---|
Component: | Database layer (models, ORM) | Version: | dev |
Severity: | Normal | Keywords: | |
Cc: | Triage Stage: | Accepted | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
From https://www.sqlite.org/changes.html#version_3_30_0
Add support for the
FILTER
clause on aggregate functions.
Even if CI is not on SQLite 3.30 it can be tested locally on Linux using LD_PRELOAD
https://github.com/orf/django-docker-box/issues/25
Change History (8)
comment:1 by , 5 years ago
comment:2 by , 5 years ago
Triage Stage: | Unreviewed → Accepted |
---|
comment:5 by , 5 years ago
Yep, I was planing on submitting a patch later today but feel free to do so if you'd like.
comment:7 by , 5 years ago
Has patch: | set |
---|---|
Owner: | changed from | to
Status: | new → assigned |
Summary: | Enable the supports_aggregate_filter_clause database feature on SQLite >= 3.30 → Enable the supports_aggregate_filter_clause database feature on SQLite >= 3.30.1 |
Note:
See TracTickets
for help on using tickets.
The suite segfaults on the following tests
aggregation.test_filter_argument.FilteredAggregateTests.test_filtered_aggregate_ref_annotation
aggregation.test_filter_argument.FilteredAggregateTests.test_filtered_aggregate_ref_subquery_annotation
It seems to be related to references from subqueries as both tests perform a subquery pushdown. I've filled a SQLite bug report about it.