Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-6940

SET STATEMENT executed after SET GLOBAL does not work

    XMLWordPrintable

Details

    Description

      Results of the test case below

      MariaDB [test]> # SET STATEMENT works (OK)
      MariaDB [test]> set statement lock_wait_timeout=1 for select @@lock_wait_timeout;
      +---------------------+
      | @@lock_wait_timeout |
      +---------------------+
      |                   1 |
      +---------------------+
      1 row in set (0.01 sec)
       
      MariaDB [test]> # Setting a totally unrelated global variable
      MariaDB [test]> set global general_log=0;
      Query OK, 0 rows affected (0.00 sec)
       
      MariaDB [test]> # SET STATEMENT does not work anymore (FAIL)
      MariaDB [test]> set statement lock_wait_timeout=1 for select @@lock_wait_timeout;
      +---------------------+
      | @@lock_wait_timeout |
      +---------------------+
      |            31536000 |
      +---------------------+
      1 row in set (0.00 sec)

      Test case

      --echo # SET STATEMENT works (OK)
      set statement lock_wait_timeout=1 for select @@lock_wait_timeout;
       
      --echo # Setting a totally unrelated global variable
      set global general_log=0;
       
      --echo # SET STATEMENT does not work anymore (FAIL)
      set statement lock_wait_timeout=1 for select @@lock_wait_timeout;

      Current revision

      commit 3a3f88e789a41b309cfe902f4823c9c7ebbce6ca
      Author: Oleksandr Byelkin <sanja@mariadb.com>
      Date:   Fri Oct 24 10:13:08 2014 +0200
       
          MDEV-5231: Per query variables from Percona Server (rewritten)
      elenst@wheezy-64:~/git/bb-10.1-set-statement$ 

      Also reproducible with Percona-server (it's even worse there).

      Attachments

        Issue Links

          Activity

            People

              sanja Oleksandr Byelkin
              elenst Elena Stepanova
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.