Quantcast
Channel: User Chase Seibert - Stack Overflow
Viewing all articles
Browse latest Browse all 43

Answer by Chase Seibert for Is it a good practice to make an index on every column that's used on a WHERE condition in a SQL database?

$
0
0

I think the best practice here is to put a few indexes in initially, as best-guesses for what indexes will be needed. But after that, you want to actually measure which queries are slow and index those. Maybe your where clauses, or even your entire queries will change as requirements change.

This could be as easy as using something that aggregates query time over the course of a day, like pgfouine.

enter image description here


Viewing all articles
Browse latest Browse all 43

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>