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

MariaDB behaviour with many JOINs

    XMLWordPrintable

Details

    • Bug
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • 10.2.16, 10.3.15, 10.4.5
    • 10.4
    • Optimizer
    • Linux x64

    Description

      I found MariaDB behaviour changing according to the number of JOINs in a query.
      In this particular application, when the number of JOINs goes from 30 to 31 the execution plan changes, causing potential problems to the execution time and resources management.
      The tests were made with few records and with millions of records: apparently this behaviour doesn't depend on the number of records, but when they are millions, the chosen plan considerably slows down execution using gigabytes of temporary files and can crash entire system.
      I couldn't find any configuration parameters that drive this behaviour, I don't know if it can be changed

      Attachments

        1. query.txt
          3 kB
        2. explain_31_join.txt
          6 kB
        3. explain_30_join.txt
          6 kB
        4. data_definition.txt
          6 kB

        Issue Links

          Activity

            People

              igor Igor Babaev
              SuperC SuperC
              Votes:
              0 Vote for this issue
              Watchers:
              5 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.