AI-powered
podcast player
Listen to all your favourite podcasts with AI-powered features
How to Analyze a Slow Database and Fix It
I was in Thailand. When we could go, I was like, Oh, why so slow? I will fix it. So I use the PG stats, then I find like,Why the query is taking eight seconds. That's very, very, very slow. And I use explain analyze and then I check a bit what I did,. Then I have to create an index on the key that I use in the order by. After that, I realized, Oh, but I'm using some left join. It doesn't work with the key. So I have to use inner choice for this case. But yeah, with PG, PG statistic, it was not too hard to find it