• unknown's avatar
    BUG#18819: DELETE IGNORE hangs on foreign key parent delete · 6ec77042
    unknown authored
    If the error happens during DELETE IGNORE, nothing could be send to the
    client, thus leaving it frozen expecting the reply.
    
    The problem was that if some error occurred, it wouldn't be reported to
    the client because of IGNORE, but neither success would be reported.
    
    MySQL 4.1 would not freeze the client, but will report
    
      ERROR 1105 (HY000): Unknown error
    
    instead, which is also a bug.
    
    The solution is to report success if we are in DELETE IGNORE and some
    non-fatal error has happened.
    
    
    mysql-test/r/innodb_mysql.result:
      Add result for bug#18819: DELETE IGNORE hangs on foreign key parent
      delete.
    mysql-test/t/innodb_mysql.test:
      Add test case for bug#18819: DELETE IGNORE hangs on foreign key parent
      delete.
    sql/sql_delete.cc:
      Report success if we have got an error, but we are in DELETE IGNORE, and
      the error is not fatal (if it is, it would be reported to the client).
    6ec77042
sql_delete.cc 19.8 KB