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

Incorrect note being written to the error log when CREATE and ALTER fail due to Row Size Too Large and in all cases for TRUNCATE and OPTIMIZE TABLE.

    XMLWordPrintable

Details

    Description

      When innodb_strict_mode is on, table creation and every alter table that would result in a too-large row size fails, issuing an error 1118:

      ERROR 1118 (42000) at line 1: Row size too large (> 8126). Changing some columns to TEXT or BLOB may help. In current row format, BLOB prefix of 0 bytes is stored inline.
      

      and logs a different but technically correct message to the error log:

      2020-05-15 11:45:03 140346379175680 [ERROR] InnoDB: Cannot add field `c181` in table `test`.`toobig12` because after adding it, the row size is 8143 which is greater than maximum allowed size (8126 bytes) for a record on index leaf page.
      

      However, when innodb_strict_mode=0 the error message becomes a warning message:

      Warning	139	Row size too large (> 8126). Changing some columns to TEXT or BLOB may help. In current row format, BLOB prefix of 0 bytes is stored inline.
      

      but the same message written to the error log as an error when innodb_strict_mode was set to 1 gets written to the error log as a warning:

      2020-05-15 11:45:03 140446790313728 [Warning] InnoDB: Cannot add field `c181` in table `test`.`toobig12` because after adding it, the row size is 8143 which is greater than maximum allowed size (8126 bytes) for a record on index leaf page.
      

      The same problem happens with TRUNCATE TABLE and OPTIMIZE TABLE operations. However, these operations succeed and write the incorrect message to the log regardless of the value of innodb_strict_mode.

      which is incorrect. The table gets successfully created with all fields including c181 and c182-c200.

      Attachments

        Issue Links

          Activity

            People

              thiru Thirunarayanan Balathandayuthapani
              juan.vera Juan
              Votes:
              0 Vote for this issue
              Watchers:
              2 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.