Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Where clause ordering
I have a question that I have gotten various answers on over time, so I'd like to ask it to all of you. When I write a query that contains more than one condition in the where clause, is it better to write the most delineating of them all first or last in the clause.
For instance - a table has a month column ( Jan - Dec ) and a date column ( 1 - 31 ). Would it be better to say "...where month = 'May' and date = 21...", or "...where date = 21 and month = 'May' ?
I've heard to put your most important one first, put your most important last, and that it didn't matter.
Any help would be greatly appreciated.
Matt Kott Received on Fri Jun 27 1997 - 00:00:00 CDT