Bug 699597 - Autocomplete using GAL is slow
authorDavid Woodhouse <David.Woodhouse@intel.com>
Mon, 20 May 2013 13:14:24 +0000 (14:14 +0100)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Mon, 20 May 2013 13:14:24 +0000 (14:14 +0100)
commitfcc0c4c89dcb01329d76f9a826dc9cb7f3d346a6
tree66cf73e33dc3e9fabe80dc5b30dddfc8aac79388
parente2fbfd981e9b7157aca00bbe5e0ced26eddeb580
Bug 699597 - Autocomplete using GAL is slow

With large addressbooks, using an inner join which produces hundreds of
thousands of duplicate results, and then filtering them back down to what
we really wanted with 'DISTINCT' is really inefficient. I can't even tell
you *how* inefficient, because it didn't complete a single query in the
hours that I left it running. Switch it to a more sensible outer join and
it completes in a second or so on my 216000-entry address book.
addressbook/libedata-book/e-book-backend-sqlitedb.c