| re: indexing
I think that indexing is good if you are doing a lot of searches for that column. I don't think you should be indexing all of those, even if you have a search or regular call to them, unless your queries are getting slow. I wouldn't even think about it until you have 10,000 records, and even then, you might not notice it until 100,000 records. Then best way to organise this is to run a timer script. Make 10,000 dummy records in a table, run a SELECT * WHERE first_name="test" query a few times to get an average for unindexed, and then index the column, and try a few time to get an average for indexed.
If you do this, please post your results and findings as it could be helpful to others. But in short, if you're not doing very populated tables, and regular searches, then don't worry about it. I would always be trying to optimize, and maybe indexing will speed it up a little, and you should run some tests to determine that. However, indexing uses memory, and could be a waste if you don't notice any difference in query time.
|