Status: Available Owner: [email protected] Labels: Type-Bug Pri-3 OS-All Area-BrowserBackend
New issue 7839 by [email protected]: Optimize FTS queries to not use OFFSET so much http://code.google.com/p/chromium/issues/detail?id=7839 Our one and only FTS query is this: SELECT url, title, time, offsets(pages), body FROM pages LEFT OUTER JOIN info ON pages.rowid = info.rowid WHERE pages MATCH ? AND time >= ? AND time < ? ORDER BY time DESC LIMIT ?" Scott says: Great, I think that your join probably will traverse things in optimal fashion. Definitely should if time isn't indexed. Note that offsets() may be expensive if you have a lot of matches which are being discarded by the constraints on 'time'. You could perhaps rephrase things using subselects. I think the breakpoint is probably if it throws around half the results away. [Of course, if it's good enough, leave it alone. offsets() is expensive in this way due to an implementation decision, it only matters if you throw more than half away due to a different implementation decision, so fts7 may totally turn the situation on its head :-).] -- You received this message because you are listed in the owner or CC fields of this issue, or because you starred this issue. You may adjust your issue notification preferences at: http://code.google.com/hosting/settings --~--~---------~--~----~------------~-------~--~----~ Automated mail from issue updates at http://crbug.com/ Subscription options: http://groups.google.com/group/chromium-bugs -~----------~----~----~----~------~----~------~--~---
