| List: | General Discussion | « Previous MessageNext Message » | |
| From: | Arthur Fuller | Date: | October 11 2011 11:42am |
| Subject: | Re: Index question | ||
| View as plain text | |||
The difference is based on the relative frequency of queries where a is important vs. where b is important. Either way, what will happen is that the index scan will isolate the first item mentioned, then scan the result set to isolate the second term. e.g. SELECT * FROM someTable WERE a = someValue and b = someOtherValue Step one isolates the matching "a" values. Step two walks through that resultset and examines each value of b. Since the values of b are already in memory, all it has to do is examine the index keys to find the matches of b. No additional disk read is required. Arthur
| Thread | ||
|---|---|---|
| • Index question | Alex Schaft | 11 Oct |
| • Re: Index question | Johan De Meersman | 11 Oct |
| • Re: Index question | Neil Tompkins | 11 Oct |
| • Re: Index question | Rik Wasmus | 11 Oct |
| • Re: Index question | Alex Schaft | 11 Oct |
| • Re: Index question | Alex Schaft | 11 Oct |
| • Re: Index question | Rik Wasmus | 11 Oct |
| • Re: Index question | Neil Tompkins | 11 Oct |
| • Re: Index question | Rik Wasmus | 11 Oct |
| • Re: Index question | Johan De Meersman | 11 Oct |
| • Re: Index question | Tompkins Neil | 11 Oct |
| • Re: Index question | Johan De Meersman | 12 Oct |
| • Re: Index question | Arthur Fuller | 11 Oct |
