I have a database that I used specifically for logging actions of users. The database has a few small tables that are aimed at specific types of actions. This data is rarely searched, but the rowcounts of the tables are starting to climb into multi-millions. I haven’t noticed a large slow down, but I want to know if indexing the table for searching will hinder or help the performance of inserts. Inserts are performed constantly but searches don’t happen so often, and the tables are just going to keep growing.
Should I create indexes on these tables? Why or why not?
This all depends on your empirical research. Take a copy of the database onto a different environment and run a profiler while running searches and inserts with and without indexes. Measure the performance and see what helps. 🙂