Right...if the database is correctly indexed and your queries are properly structured to use the indexes, your queries will be much faster (at the cost of insert and update time, but most databases are read MUCH more than updated).
If you read up some more on indexes you will find that you can probably build a a few indexes for most of your queries. I'm not sure if this was in Tim's article I mentioned in my last reply or not.
Let's say you have a table User with columns userID, userName, userPass, and userEmail. If you plan on searching by userName in one query and userName AND userEmail in another query, you can use 1 index:
CREATE INDEX User_userName_userEmail on Users (userName, userEmail);
These selects will use the index:
SELECT * FROM User WHERE userName LIKE '%root%';
SELECT userPass FROM User WHERE userName = 'root';
SELECT userName FROM User WHERE userName LIKE '%test%' AND userEmail LIKE 'test@%';
SELECT userName FROM User WHERE userName = 'root' AND userEmail LIKE 'root@%' AND userPass = 'stayout';
But these selects will NOT use the index:
SELECT from User WHERE userEmail LIKE 'test@%' AND userName LIKE '%test%';
SELECT from User WHERE userEmail = 'test@test.com';
The 'where' clauses must be in the same order as the order the index was created, starting from the left to use an index.
I hope I didn't get anything wrong here...I'm pretty sure this is right.
-Rich