On Fri, 23 Jul 2021 at 03:56, Tom Lane <tgl@xxxxxxxxxxxxx> wrote: > So basically, we now have a hard restriction that hashaggs can't use > more than INT_MAX kilobytes, or approximately 2.5GB, and this use case > is getting eaten alive by that restriction. Seems like we need to > do something about that. Hmm, math check? postgres=# select pg_size_pretty(power(2,31)::numeric*1024); pg_size_pretty ---------------- 2048 GB (1 row) David