On Thu, Oct 02, 2008 at 03:20:31PM +0200, Sergei Golubchik wrote:
> Hi, Sergey!
>
> On Oct 02, Sergey Petrunia wrote:
> > Hi!
> >
> > On Sat, Sep 20, 2008 at 02:16:15AM +0500, Gleb Shchepa wrote:
> > > #At file:///work/bzr/5.0-bugteam-37894/
> > >
> > > 2662 Gleb Shchepa 2008-09-20
> > > Bug #37894: Assertion in init_read_record_seq in handler.h
> > > line 1444
> > >
> > > Select with a "NULL NOT IN" condition containing complex
> > > subselect from the same table as in the outer select failed
> > > with an assertion.
> >
> > More, I believe that there is no need to have additional handler
> > object at all. It should be easy to examine handler->inited,
> > handler->active_index, save their state and restore it at the end of
> > the scan, please do so. (If it's not that trivial then I'm missing
> > something, please let me know).
>
> You cannot easily save the state of the handler, as you have no access
> to it. Most of the state is inside the storage engine, probably spead
> over different (internal to the storage engine) structures.
And we don't need any of that for this bug, because
* the scan will be restarted (so, there's no need, e.g. to save index scan
position).
* we aren't making arbitrary changes. We just switch to full table scan,
then switch back.
BR
Sergey
--
Sergey Petrunia, Lead Software Engineer
MySQL AB, www.mysql.com
Office: N/A
Blog: http://s.petrunia.net/blog