@emersion@octodon.social For public record, I haven't found great articles explaining this. //www.percona.com/blog/sql-optimizations-in-postgresql-in-vs-exists-vs-any-all-vs-join/ shows an example where a small subquery outperforms a join, although normally joins tend to be faster. (And databases often treat exactly the same a subquery and the equivalent join.)