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?.
email_id | user_id | |
---|---|---|
1 | 1 | abc@d.com |
2 | 2 | def3@d.com |
3 | 3 | ghi1@d.com |
user_id | username | email_id |
---|---|---|
1 | usr1 | 1 |
2 | usr2 | 2 |
3 | usr3 | 3 |
email_id | user_id | |
---|---|---|
1 | 1 | abc@d.com |
2 | 2 | def3@d.com |
3 | 3 | ghi1@d.com |
user_id | email_id | username | |
---|---|---|---|
1 | 1 | usr1 | abc@d.com |
2 | 2 | usr2 | def3@d.com |
3 | 3 | usr3 | ghi1@d.com |
user_id | username | email_id | email_id | user_id | |
---|---|---|---|---|---|
3 | usr3 | 4 | 4 | 3 | new_active@d.com |
email_id | user_id | |
---|---|---|
1 | 1 | abc@d.com |
2 | 2 | def3@d.com |
3 | 3 | ghi1@d.com |
4 | 3 | new_active@d.com |
user_id | email_id | username | |
---|---|---|---|
1 | 1 | usr1 | abc@d.com |
2 | 2 | usr2 | def3@d.com |
3 | 4 | usr3 | new_active@d.com |