• Sergei Petrunia's avatar
    MDEV-30569: Assertion ...ha_table_flags() in Duplicate_weedout_picker::check_qep · a7666952
    Sergei Petrunia authored
    DuplicateWeedout semi-join optimization requires that the tables in
    the parent subquery provide rowids that can be compared across table
    scans. Most engines support this, federated is the only exception.
    
    DuplicateWeedout is the default catch-all semi-join strategy, which
    must be always available. If it is not available for some edge case,
    it's better to disable semi-join conversion altogether.
    
    This is what was done in the fix for MDEV-30395. However that fix
    has put the check before the view processing, so it didn't detect
    federated tables inside mergeable VIEWs.
    
    This patch moves the check to be done at a later phase, when mergeable
    views are already merged.
    a7666952
opt_subselect.cc 247 KB