• Aleksey Midenkov's avatar
    MDEV-18929 2nd execution of SP does not detect ER_VERS_NOT_VERSIONED · f6d8640d
    Aleksey Midenkov authored
    Related to 87731177 and Bug#47649.
    
    Don't set Query_arena::STMT_EXECUTED for any error
    code. skip_setup_conds() depends on STMT_INITIALIZED_FOR_SP, but
    sp_lex_keeper::reset_lex_and_exec_core() sets it to STMT_EXECUTED on
    ER_TABLE_NOT_LOCKED_FOR_WRITE. There are other error codes that can
    break skip_setup_conds() (ER_IT_IS_A_VIEW, ER_NON_UPDATABLE_TABLE,
    etc).
    f6d8640d
sp_head.cc 143 KB