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

CONNECT engine does not quote columns involved in WHERE clause

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Confirmed (View Workflow)
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 10.2, 10.3, 10.4, 10.5, 10.6, 10.7, 10.8, 10.7.3
    • Fix Version/s: 10.2, 10.3, 10.4, 10.5, 10.6, 10.7
    • Labels:
    • Environment:
      10.7.3-MariaDB-1:10.7.3+maria~focal-log from docker image for both source and CONNECT servers. `dpkg -s mariadb-plugin-connect | grep Version` reports `Version: 1:10.7.3+maria~focal` for connect plugin

      Description

      Hello,

      I have noticed that the connect engine does not properly quote columns in WHERE when the table type is MySQL. For example, issuing the following query against a CONNECT database:

      SELECT `ID` FROM t1 WHERE t1.`spaced col` = 'C-003';
      

      will issue the following against the main server:

      SELECT `ID`, `spaced col` FROM `t1` WHERE spaced col= 'C-003';
      

      Note how the WHERE clause is unquoted, which raises a syntax error.

        Attachments

          Activity

            People

            Assignee:
            anel Anel Husakovic
            Reporter:
            tgross35 Trevor Gross
            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.