• anozdrin/alik@alik.opbmk's avatar
    Fix for BUG#25082: default database change on trigger · cc83bb07
    anozdrin/alik@alik.opbmk authored
    execution breaks replication.
    
    When a stored routine is executed, we switch current
    database to the database, in which the routine
    has been created. When the stored routine finishes,
    we switch back to the original database.
    
    The problem was that if the original database does not
    exist (anymore) after routine execution, we raised an error.
    
    The fix is to report a warning, and switch to the NULL database.
    cc83bb07
sp_head.cc 93.8 KB