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

Userstat does not register updated/deleted/read rows for Columnstore tables

    XMLWordPrintable

Details

    Description

      10.11.7 release

      MariaDB [test]> set global userstat=1;
      Query OK, 0 rows affected (0.001 sec)
       
      MariaDB [test]> create table t (a int) engine=columnstore;
      Query OK, 0 rows affected (0.855 sec)
       
      MariaDB [test]> show table_statistics \G
      Empty set (0.001 sec)
       
      MariaDB [test]> insert into t values (1),(2);
      Query OK, 2 rows affected (0.298 sec)
      Records: 2  Duplicates: 0  Warnings: 0
       
      MariaDB [test]> show table_statistics \G
      *************************** 1. row ***************************
                 Table_schema: test
                   Table_name: t
                    Rows_read: 0
                 Rows_changed: 2
      Rows_changed_x_#indexes: 2
      1 row in set (0.001 sec)
       
      MariaDB [test]> update t set a = 3 where a = 1;
      Query OK, 1 row affected (1.236 sec)
      Rows matched: 1  Changed: 1  Warnings: 0
       
      MariaDB [test]> select * from t;
      +------+
      | a    |
      +------+
      |    3 |
      |    2 |
      +------+
      2 rows in set (0.017 sec)
       
      MariaDB [test]> delete from t where a = 3;
      Query OK, 1 row affected (0.181 sec)
       
      MariaDB [test]> show table_statistics \G
      *************************** 1. row ***************************
                 Table_schema: test
                   Table_name: t
                    Rows_read: 0
                 Rows_changed: 2
      Rows_changed_x_#indexes: 2
      1 row in set (0.001 sec)
      

      So, Rows_changed is only incremented upon INSERT, and Rows_read apparently not at all.

      Same is true for extensions added in MDEV-33151Rows_inserted is incremented, Rows_updated and Rows_deleted are not.

      I only tried 10.11 and 11.5-based branch with MDEV-33151, other versions listed in "affected versions" are an extrapolation.
      I didn't try 10.5 and didn't put it there as Columnstore 5.x is not actively maintained anyway.

      Attachments

        Activity

          People

            monty Michael Widenius
            elenst Elena Stepanova
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

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