|
[
Permalink
| « Hide
]
Dmitry Yemanov added a comment - 20/Feb/07 02:14 PM
RelNotes, page 102, "ALL predicate may be slow". It applies to NOT IN the same way.
Execute time = 7m 50s. Everything is "as designed" (although I do understand that not everybody's happy, sigh).
Now I see, it's THIS one. Well, I would not expect it's so bad on just few records. The sample database has:
KONTAKTE: Average record length: 37.77, total records: 223228, Data pages: 17769 STAMM: Average record length: 18.93, total records: 9448, Data pages: 572 As it utilizes CPU on 100%, it makes FB unusable in this case especially in multi-user environment. Anyway, it's not a bug as it fixes another critical bug, but it's an important regression, so I'll change it to improvement with critical priority. We have to do something about it soon. I do not think it's possible to do something with it. To satisfy SQL standard, we can not use indices. As long as we do not use them, 100% CPU utilization is typical. I had to review all applications, when moving to FB2, in order to change "not in" to "not exists", which works fine and does exactly what "not in" did before.
BTW, may be SORT + MERGE may be used in such cases? The only more-or-less easy solution is to cache the subsquery rowset. The engine never did that (except for SORT, but that's just an implementation detail), so some major changes are requred. I have RsbBuffer implemented locally, but I don't think we should add it to the public codebase yet.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||