I wrote:> What I'm wondering is why this plan was accepted at all. Does PHJ> not consider work_mem or a similar limit on hash table size?
Ah, found it. See
https://www.postgresql.org/message-id/2380165.1766871097%40sss.pgh.pa.us
regards, tom lane