Ran into this on my benchmark data set! Canceled a query that had already run for two days, found this plan: Nested Loop (cost=78,613,867,046.43 rows=20,718,100 width=1144) Oopsie! Add missing index, 6 minutes: Nested Loop (cost= 1,881,853,963.95 rows=495,950 width=1144)
Postgres performance best practice: index all foreign keys. Primary keys are automatically indexed but if you reference a primary key in another table using a foreign key, that is not automatically indexed - and an index needs to be added manually.
6
7
79
59
7K
0
0
1
0
43
United States Xu hướng
- 1. Rob Reiner 241K posts
- 2. #ITWelcomeToDerry 162K posts
- 3. All in the Family 28.9K posts
- 4. Cowboys 37.9K posts
- 5. Stand By Me 18.9K posts
- 6. When Harry Met Sally 19.2K posts
- 7. Meathead 7,273 posts
- 8. The Princess Bride 16.7K posts
- 9. Spinal Tap 16.7K posts
- 10. Brentwood 20K posts
- 11. Pennywise 60K posts
- 12. LAPD 9,335 posts
- 13. Brooks 33.2K posts
- 14. JJ McCarthy 8,522 posts
- 15. Richie 36.4K posts
- 16. Steph 33.3K posts
- 17. Vikings 30K posts
- 18. #BaddiesUSA 22K posts
- 19. Toluca 65.9K posts
- 20. Eberflus 6,651 posts
Loading...
Something went wrong.
Something went wrong.