• kostja@bodhi.local's avatar
    A fix and a test case for Bug#21002 "Derived table not selecting from a · f22a4ce1
    kostja@bodhi.local authored
    "real" table fails in JOINs".
    
    This is a regression caused by the fix for Bug 18444. 
    This fix removed the assignment of empty_c_string to table->db performed 
    in add_table_to_list, as neither me nor anyone else knew what it was 
    there for. Now we know it and it's covered with tests: the only case 
    when a table database name can be empty is when the table is a derived 
    table. The fix puts the assignment back but makes it a bit more explicit.
    
    Additionally, finally drop sp.result.orig which was checked in by mistake. 
    f22a4ce1
sp.test 126 KB