[thelist] MySQL optimization
Anthony Ettinger
apwebdesign at yahoo.com
Tue Sep 27 12:28:43 CDT 2005
--- Steve Lewis <nepolon at worlddomination.net> wrote:
> Query:
> select DISTINCT sectionid
> from SectionMembers LEFT JOIN Sections ON
> Sections.id=SectionMembers.sectionid
> where Sections.instid = '%bindVal01%'
>
> SectionMembers is an association table joining
> groups (sections) to
> users (members). The SectionMembers table has more
> than 100k rows.
>
> Does anyone see any way to remove the DISTINCT or
> identify other
> optimizations for this query?
>
Have you defined indexes for the fields you're joining
on?
Anthony Ettinger
ph: (408) 656-2473
blog: http://www.chovy.com
__________________________________
Yahoo! Mail - PC Magazine Editors' Choice 2005
http://mail.yahoo.com
More information about the thelist
mailing list