django/django — pull request #3779 by akaariai (2014-12-23 13:09:52+00:00)
Title: [WIP] Initial work on moving split_having to compile stage

The idea is to split the where and having parts in compiler stage. This should be faster on those queries that do not use aggregates, and the logic is easier to implement in compiler.