On 5/6/2019 5:19 PM, Shawn Wagner wrote:
I just found out that postgres (And possibly others?) supports FILTER on
aggregate functions in general, not just when they're used as a window
function.
Trivial example:
SELECT count(*), count(*) FILTER (WHERE amount > 100) FROM blah
which is a lo
I just found out that postgres (And possibly others?) supports FILTER on
aggregate functions in general, not just when they're used as a window
function.
Trivial example:
SELECT count(*), count(*) FILTER (WHERE amount > 100) FROM blah
which is a lot cleaner than
SELECT count(*), sum(CAS
2 matches
Mail list logo