• "When to index" isn't a question of the query. Not really. It's a question of what you're trying to do.

    There's no way to tell, from what you wrote, wether you should index something or not.

    Start out with a book on performance tuning. Read online articles on it, too, but pick out a good book as a first step.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon