TX_084896· Engineering
exists and non-sparse indexes in mongodb and documentdb
MongoDB's $exists queries on non-sparse indexes trigger a residual fetch, while Amazon DocumentDB ignores the index and Microsoft's DocumentDB-on-PostgreSQL behaves differently. Sparse indexes eliminate the wasted work [Dev.to].