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

Server audit: ANALYZE <INSERT|REPLACE|UPDATE|DELETE> is not recognized as DML

    XMLWordPrintable

Details

    Description

      ANALYZE INSERT/REPLACE/UPDATE/DELETE is another way to execute the DML, but it's not recognized as DML by audit parsing.

      MariaDB [test]> set global server_audit_events = query_dml;
      Query OK, 0 rows affected (0.00 sec)
       
      MariaDB [test]> delete from t1;
      Query OK, 0 rows affected (0.00 sec)
       
      MariaDB [test]> analyze insert into t1 values (1);
      +------+-------------+-------+------+---------------+------+---------+------+------+--------+----------+------------+-------+
      | id   | select_type | table | type | possible_keys | key  | key_len | ref  | rows | r_rows | filtered | r_filtered | Extra |
      +------+-------------+-------+------+---------------+------+---------+------+------+--------+----------+------------+-------+
      |    1 | INSERT      | t1    | ALL  | NULL          | NULL | NULL    | NULL | NULL |   NULL |   100.00 |     100.00 | NULL  |
      +------+-------------+-------+------+---------------+------+---------+------+------+--------+----------+------------+-------+
      1 row in set (0.08 sec)
       
      MariaDB [test]> select * from t1;
      +------+
      | i    |
      +------+
      |    1 |
      +------+
      1 row in set (0.00 sec)

      20150114 19:39:51,wheezy-64,root,localhost,2,26,QUERY,test,'delete from t1',0
      20150114 19:39:58,wheezy-64,root,localhost,2,28,QUERY,test,'select * from t1',0
      Waiting for data... (interrupt to abort)

      Attachments

        Activity

          People

            holyfoot Alexey Botchkov
            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.