Thread

  1. Re: [PATCHES] Re: [HACKERS] Query->hasSubLinks is always FALSE...

    Vadim B. Mikheev <vadim@sable.krasnoyarsk.su> — 1998-02-09T16:28:13Z

    Bruce Momjian wrote:
    > 
    > You know, after all our lengthy discussions, this SubLink thing looks
    > pretty clean to me.
    > 
    > How are subselects going?  Are you having to write a lot of code to get
    > it working?  I would say after all our discussions and thinking, it took
    
    Mmm ... =~ 1000 lines of code :)
    
    > me about two or three days to do the parser and rewrite for sublinks.
    > How many coding days is the rest taking?  I am curious.
    
    All was near ready Feb 6, but ... I got problems from canonification
    routines in optimizer: 'where A AND B OR C ' becomes 'where (A OR C) AND (B OR C)'
    and if C is subselect then ... C has to be processed twice (sometime) ...
    I remember your question about handling 'A AND (B OR SubSelect)' - unfortunately,
    I didn't see problems here (actually, there is no problem with this
    conjunctive normal form :), but there are troubles in common case.
    
    Ideas ?
    
    For the moment I could leave this un-optimized, with possibility
    of double subselect processing...
    
    Vadim
    
    
  2. Re: [PATCHES] Re: [HACKERS] Query->hasSubLinks is always FALSE...

    Bruce Momjian <maillist@candle.pha.pa.us> — 1998-02-09T17:33:59Z

    > 
    > Bruce Momjian wrote:
    > > 
    > > You know, after all our lengthy discussions, this SubLink thing looks
    > > pretty clean to me.
    > > 
    > > How are subselects going?  Are you having to write a lot of code to get
    > > it working?  I would say after all our discussions and thinking, it took
    > 
    > Mmm ... =~ 1000 lines of code :)
    > 
    > > me about two or three days to do the parser and rewrite for sublinks.
    > > How many coding days is the rest taking?  I am curious.
    > 
    > All was near ready Feb 6, but ... I got problems from canonification
    > routines in optimizer: 'where A AND B OR C ' becomes 'where (A OR C) AND (B OR C)'
    > and if C is subselect then ... C has to be processed twice (sometime) ...
    > I remember your question about handling 'A AND (B OR SubSelect)' - unfortunately,
    > I didn't see problems here (actually, there is no problem with this
    > conjunctive normal form :), but there are troubles in common case.
    > 
    > Ideas ?
    > 
    > For the moment I could leave this un-optimized, with possibility
    > of double subselect processing...
    
    I would leave it for later.  We already have an optimizer explosion
    problem when we have lots of OR's so at some point we may have to
    revisit the cnf-ify process anyway.  Commerical Ingres has or had the
    same problem.
    
    
    -- 
    Bruce Momjian
    maillist@candle.pha.pa.us
    
    
  3. Re: [PATCHES] Re: [HACKERS] Query->hasSubLinks is always FALSE...

    Vadim B. Mikheev <vadim@sable.krasnoyarsk.su> — 1998-02-09T17:56:06Z

    Bruce Momjian wrote:
    > 
    > >
    > > > me about two or three days to do the parser and rewrite for sublinks.
    > > > How many coding days is the rest taking?  I am curious.
    > >
    > > All was near ready Feb 6, but ... I got problems from canonification
    > > routines in optimizer: 'where A AND B OR C ' becomes 'where (A OR C) AND (B OR C)'
    > > and if C is subselect then ... C has to be processed twice (sometime) ...
    > > I remember your question about handling 'A AND (B OR SubSelect)' - unfortunately,
    > > I didn't see problems here (actually, there is no problem with this
    > > conjunctive normal form :), but there are troubles in common case.
    > >
    > > Ideas ?
    > >
    > > For the moment I could leave this un-optimized, with possibility
    > > of double subselect processing...
    > 
    > I would leave it for later.  We already have an optimizer explosion
    > problem when we have lots of OR's so at some point we may have to
    > revisit the cnf-ify process anyway.  Commerical Ingres has or had the
    > same problem.
    
    Ok, follow this way...
    
    Vadim