Uploaded image for project: 'MariaDB MaxScale'
  1. MariaDB MaxScale
  2. MXS-4307

Parser can't recognize convert function parameters and cause wrong routing decision

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.4, 2.5, 6.4, 22.08
    • Fix Version/s: 6.4.3, 22.08.2
    • Component/s: qc_sqlite
    • Labels:
      None

      Description

      select CONVERT(substring(receive_code,8), UNSIGNED INTEGER) as sort, `id`, `receive_code` from `hz_lab_sample_receive` where `created_at` >= '2022-09-16 00:00:00' and `laboratory_code` = LY0023A order by `sort` desc limit 1 lock in share mode;
      

      in `CONVERT(substring(receive_code,8), UNSIGNED INTEGER)`, UNSIGNED INTEGER is not recognized.

      The SQL is parsed as QUERY_TYPE_READ.
      `lock in share mode` has no chance of parsing.

        Attachments

          Activity

            People

            Assignee:
            johan.wikman Johan Wikman
            Reporter:
            daniel_xu_forever danielforever
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.