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?.
7 rows affected
id | date | account_id | browser_cookie_id | prev_group_date | prev_date |
---|---|---|---|---|---|
1 | 2020-1-1 | e12345 | 123 | null | null |
3 | 2020-1-3 | e67890 | 123 | null | 2020-1-2 |
6 | 2020-1-5 | e67890 | 456 | null | 2020-1-4 |
5 | 2020-1-5 | e12345 | 123 | 2020-1-2 | 2020-1-5 |
7 | 2020-1-6 | e12345 | 789 | null | 2020-1-5 |