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

`COUNT()` function returns random values ocassionally

    XMLWordPrintable

Details

    • Bug
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • None
    • None
    • None
    • None

    Description

      Hello,

      If there is an error in my query, please let me know. Our internal ERP software runs this query to fetch a list of all SKUs shared between our two companies, and uses `COUNT(CASE)` functions to get the the count of rows in the inventory table of both companies.

      Pastebin to Query

      The issue comes up the first 27 SKUs return quantity perfectly, and then from there the in stock quantity for both companies get seemingly multiplied by itself 2 or 3 times randomly . If needed, I can potentially provide a mariadbdump for both companies inventory tables (in different databases) and the central products table.

      Attachments

        Activity

          People

            Unassigned Unassigned
            hlafaille Hunter LaFaille
            Votes:
            0 Vote for this issue
            Watchers:
            3 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.