• Debarun Banerjee's avatar
    BUG#20310212 PARTITION DDL- CRASH AFTER THD::NOCHECK_REGISTER_ITEM_ · 0eadadad
    Debarun Banerjee authored
    Problem :
    ---------
    Issue-1: The root cause for the issues is that (col1 > 1) is not a
    valid partition function and we should have thrown error at much early
    stage [partition_info::check_partition_info]. We are not checking
    sub-partition expression when partition expression is NULL.
    
    Issue-2: Potential issue for future if any partition function needs to
    change item tree during open/fix_fields. We should release changed
    items, if any, before doing closefrm when we open the partitioned table
    during creation in create_table_impl.
    
    Solution :
    ----------
    1.check_partition_info() - Check for sub-partition expression even if no
    partition expression.
    [partition by ... columns(...) subpartition by hash(<expr>)]
    
    2.create_table_impl() - Assert that the change list is empty before doing
    closefrm for partitioned table. Currently no supported partition function
    seems to be changing item tree during open.
    Reviewed-by: default avatarMattias Jonsson <mattias.jonsson@oracle.com>
    
    RB: 9345
    0eadadad
sql_table.cc 244 KB