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

mysqldump will create a dump with indexes ordered by "type and creation time" instead of "type and name"

    XMLWordPrintable

    Details

      Description

      We use:

      mysqldump --compact --no-data
      

      to extract all the tables definitions.
      We then strip the AUTO_INCREMENTS with SED:

      sed \'s/ AUTO_INCREMENT=[0-9]*//g\'
      

      The output is then hashed in order to check table version across different servers.
      We realize that few time the comparison doesn't match because INDEX are dumped by: "indextype ASC, creation ASC" instead of "indextype ASC, indexname ASC".
      So 2 identical table structure will be different just because a developer added an index before another. This is weird.

      Is it possible to force the dump of the indexes by type and then by alphabetical order?

        Attachments

          Activity

            People

            Assignee:
            serg Sergei Golubchik
            Reporter:
            maxcuttins Massimiliano Cuttini
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Git Integration