By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
Help with an interesting Postgres question: Why isn't an Index Only Scan used on a partition accessed via the parent table?.
id | json |
---|---|
1 | {"1":"111", "2":"222"} |
2 | {"1":"111", "2":"333"} |
3 | {"1":"444", "2":"222"} |
4 | {"1":"666", "2":"111"} |
5 | {"1":"777", "2":"888"} |
SELECT 5
id | json |
---|---|
1 | {"1":"111", "2":"222"} |
2 | {"1":"111", "2":"333"} |
4 | {"1":"666", "2":"111"} |
SELECT 3