1. 28 Feb, 2018 1 commit
  2. 27 Feb, 2018 2 commits
    • Alexander Barkov's avatar
    • Alexander Barkov's avatar
      MDEV-11952 Oracle-style packages: stage#5 · 5f7c764f
      Alexander Barkov authored
      Backporting from bb-10.2-compatibility to bb-10.2-ext
      
      Version: 2018-01-26
      
      - CREATE PACKAGE [BODY] statements are now
        entirely written to mysql.proc with type='PACKAGE' and type='PACKAGE BODY'.
      - CREATE PACKAGE BODY now supports IF NOT EXISTS
      - DROP PACKAGE BODY now supports IF EXISTS
      - CREATE OR REPLACE PACKAGE [BODY] is now supported
      - CREATE PACKAGE [BODY] now support the DEFINER clause:
      
          CREATE DEFINER user@host PACKAGE pkg ... END;
          CREATE DEFINER user@host PACKAGE BODY pkg ... END;
      
      - CREATE PACKAGE [BODY] now supports SQL SECURITY and COMMENT clauses, e.g.:
      
          CREATE PACKAGE p1 SQL SECURITY INVOKER COMMENT "comment" AS ... END;
      
      - Package routines are now created from the package CREATE PACKAGE BODY
        statement and don't produce individual records in mysql.proc.
      
      - CREATE PACKAGE BODY now supports package-wide variables.
        Package variables can be read and set inside package routines.
        Package variables are stored in a separate sp_rcontext,
        which is cached in THD on the first packate routine call.
      
      - CREATE PACKAGE BODY now supports the initialization section.
      
      - All public routines (i.e. declared in CREATE PACKAGE)
        must have implementations in CREATE PACKAGE BODY
      
      - Only public package routines are available outside of the package
      
      - {CREATE|DROP} PACKAGE [BODY] now respects CREATE ROUTINE and ALTER ROUTINE
        privileges
      
      - "GRANT EXECUTE ON PACKAGE BODY pkg" is now supported
      
      - SHOW CREATE PACKAGE [BODY] is now supported
      
      - SHOW PACKAGE [BODY] STATUS is now supported
      
      - CREATE and DROP for PACKAGE [BODY] now works for non-current databases
      
      - mysqldump now supports packages
      
      - "SHOW {PROCEDURE|FUNCTION) CODE pkg.routine" now works for package routines
      
      - "SHOW PACKAGE BODY CODE pkg" now works (the package initialization section)
      
      - A new package body level MDL was added
      
      - Recursive calls for package procedures are now possible
      
      - Routine forward declarations in CREATE PACKATE BODY are now supported.
      
      - Package body variables now work as SP OUT parameters
      
      - Package body variables now work as SELECT INTO targets
      
      - Package body variables now support ROW, %ROWTYPE, %TYPE
      5f7c764f
  3. 25 Feb, 2018 3 commits
    • Alexander Barkov's avatar
      MDEV-11952 Oracle-style packages: stage#5 · 583eb96c
      Alexander Barkov authored
      - CREATE PACKAGE [BODY] statements are now
        entirely written to mysql.proc with type='PACKAGE' and type='PACKAGE BODY'.
      - CREATE PACKAGE BODY now supports IF NOT EXISTS
      - DROP PACKAGE BODY now supports IF EXISTS
      - CREATE OR REPLACE PACKAGE [BODY] is now supported
      - CREATE PACKAGE [BODY] now support the DEFINER clause:
      
          CREATE DEFINER user@host PACKAGE pkg ... END;
          CREATE DEFINER user@host PACKAGE BODY pkg ... END;
      
      - CREATE PACKAGE [BODY] now supports SQL SECURITY and COMMENT clauses, e.g.:
      
          CREATE PACKAGE p1 SQL SECURITY INVOKER COMMENT "comment" AS ... END;
      
      - Package routines are now created from the package CREATE PACKAGE BODY
        statement and don't produce individual records in mysql.proc.
      
      - CREATE PACKAGE BODY now supports package-wide variables.
        Package variables can be read and set inside package routines.
        Package variables are stored in a separate sp_rcontext,
        which is cached in THD on the first packate routine call.
      
      - CREATE PACKAGE BODY now supports the initialization section.
      
      - All public routines (i.e. declared in CREATE PACKAGE)
        must have implementations in CREATE PACKAGE BODY
      
      - Only public package routines are available outside of the package
      
      - {CREATE|DROP} PACKAGE [BODY] now respects CREATE ROUTINE and ALTER ROUTINE
        privileges
      
      - "GRANT EXECUTE ON PACKAGE BODY pkg" is now supported
      
      - SHOW CREATE PACKAGE [BODY] is now supported
      
      - SHOW PACKAGE [BODY] STATUS is now supported
      
      - CREATE and DROP for PACKAGE [BODY] now works for non-current databases
      
      - mysqldump now supports packages
      
      - "SHOW {PROCEDURE|FUNCTION) CODE pkg.routine" now works for package routines
      
      - "SHOW PACKAGE BODY CODE pkg" now works (the package initialization section)
      
      - A new package body level MDL was added
      
      - Recursive calls for package procedures are now possible
      
      - Routine forward declarations in CREATE PACKATE BODY are now supported.
      
      - Package body variables now work as SP OUT parameters
      
      - Package body variables now work as SELECT INTO targets
      
      - Package body variables now support ROW, %ROWTYPE, %TYPE
      583eb96c
    • Sergei Golubchik's avatar
      MDEV-15405 Mixed replication fails with "Could not execute Delete_rows_v1... · 83ea839f
      Sergei Golubchik authored
      MDEV-15405 Mixed replication fails with "Could not execute Delete_rows_v1 event" upon DELETE HISTORY
      
      Allow slave thread to set time for system versioning
      
      Note that every binlog event stores now(0), while microseconds
      are only stored when they're actually used in the query.
      
      Meaning for unversioned->versioned replication, there will be
      no microseconds. Need to compensate for that.
      83ea839f
    • Sergei Golubchik's avatar
      fix THD::system_time to follow, well, system time · ac2d4d49
      Sergei Golubchik authored
      Because NOW() is set to system time, unless overriden.
      And both should follow big manual system time changes,
      while still coping with lowres system clocks.
      
      Ignoring system time changes is both confusing and
      breaks with restarts.
      ac2d4d49
  4. 24 Feb, 2018 11 commits
  5. 23 Feb, 2018 23 commits