On 17th of July, Noah Misch committed patch:
Implement the FILTER clause for aggregate function calls. This is SQL-standard with a few extensions, namely support for subqueries and outer references in clause expressions. catversion bump due to change in Aggref and WindowFunc. David Fetter, reviewed by Dean Rasheed.
Continue reading Waiting for 9.4 – Implement the FILTER clause for aggregate function calls.