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?.
CREATE TABLE
INSERT 0 6
bundesland | startdate | enddate | count |
---|---|---|---|
Hessen | 2015-02-26 16:22:21 | 2015-02-26 16:31:31 | 2 |
Hessen | 2015-10-20 22:34:54 | 2015-10-20 22:35:03 | 2 |
Bremen | 2015-10-20 22:35:50 | 2015-10-20 22:37:03 | 1 |
Hessen | 2015-02-26 11:22:21 | 2015-02-26 16:31:31 | 1 |
Hessen | 2015-10-20 21:34:54 | 2015-10-20 22:35:03 | 1 |
Bremen | 2015-10-21 22:35:50 | 2015-10-21 22:37:03 | 1 |
SELECT 6