• unknown's avatar
    Bug#20028 (Function with select return no data) · 5bd58f3e
    unknown authored
    This patch reverts a change introduced by Bug 6951, which incorrectly
    set thd->abort_on_warning for stored procedures.
    
    As per internal discussions about the SQL_MODE=TRADITIONAL,
    the correct behavior is to *not* abort on warnings even inside an INSERT/UPDATE
    trigger.
    
    Tests for Stored Procedures, Stored Functions, Triggers involving SQL_MODE
    have been included or revised, to reflect the intended behavior.
    
    (reposting approved patch, to work around source control issues, no review needed)
    
    
    mysql-test/include/sp-vars.inc:
      Tests for SQL_MODE='TRADITIONAL'
    mysql-test/r/sp-vars.result:
      Tests for SQL_MODE='TRADITIONAL'
    mysql-test/r/sp.result:
      Tests for SQL_MODE='TRADITIONAL'
    mysql-test/r/trigger.result:
      Tests for SQL_MODE='TRADITIONAL'
    mysql-test/t/sp-vars.test:
      Tests for SQL_MODE='TRADITIONAL'
    mysql-test/t/sp.test:
      Tests for SQL_MODE='TRADITIONAL'
    mysql-test/t/trigger.test:
      Tests for SQL_MODE='TRADITIONAL'
    sql/sp_head.cc:
      For SQL_MODE='TRADITIONAL',
      thd->abort_on_warning should be set only when assigning a *column*
    5bd58f3e
sp-vars.result 29.4 KB