PostgreSQL: NOT IN versus EXCEPT performance difference (edited #2)

前端 未结 5 543
萌比男神i
萌比男神i 2020-12-15 04:01

I have two queries that are functionally identical. One of them performs very well, the other one performs very poorly. I do not see from where the performance difference ar

5条回答
  •  清歌不尽
    2020-12-15 04:44

    The second query makes usage of the HASH JOIN feature of postgresql. This is much faster then the Seq Scan of the first one.

提交回复
热议问题