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

Add a SHOW WARNINGS SUMMARY function.

    Details

    • Type: Task
    • Status: Open (View Workflow)
    • Priority: Minor
    • Resolution: Unresolved
    • Fix Version/s: None
    • Component/s: Server
    • Labels:
      None

      Description

      Hi,

      in [1], I presented an example of a statement that produce 50 million and twelve (50,000,012) warnings. All those cannot be reported by SHOW WARNINSG as the maximum value of max_error_count is 64K (as a side note, I agree that it does not make sense to buffer that many warnings). However, losing all information about those warnings is bad. A way to keep some information about those would be useful. This is the object of this feature request.

      [1]: http://jfg-mysql.blogspot.com/2017/01/upgrading-mariadb-failed-because-ignoring-warnings.html

      I suggest adding a "SHOW WARNINGS SUMMARY" statement. This would return a list of warning code, with their occurrence count, and with the associated generic warning message.

      In the case of [1], the output of "SHOW WARNINGS SUMMARY" could be something like:

      +---------+------+----------+--------------------------------------------------+
      | Level   | Code | Count    | Message                                          |
      +---------+------+----------+--------------------------------------------------+
      | Warning | 1366 | 50000000 | Incorrect integer value: ? for column ? at row ? |
      | Warning | ...  |        1 | ...                                              |
      | Warning | ...  |      ... | ...                                              |
      +---------+------+----------+--------------------------------------------------+
      

      As of another feature request (MDEV-11834), "SHOW WARNINGS SUMMARY" should not report warnings that have been "hidden". So a "SHOW ALL WARNINGS SUMMARY" could also be implemented to allow to show the hidden warnings.

      Many thanks,

      JFG

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              jeanfrancois.gagne Jean-François Gagné
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated: