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

Column alias named "engine" without backticks returns an error

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.2.3
    • Fix Version/s: 2.2.4, 2.1.16
    • Component/s: qc_sqlite
    • Labels:
      None

      Description

      Described query with using alias named engine without using backticks (``) does not work:

      select id as engine from users WHERE id = 1;
      

      But this one works:

      select id as `engine` from users WHERE id = 1;
      

      Both of this queries successful work in MariaDB 10.2

      Add. information:
      Query:

      mysql> select id as engine from users WHERE id = 1;
      ERROR 1141 (HY000): Access denied for user 'docker'@'172.18.0.1': Query could not be parsed completely and will hence be rejected. Please ensure that the SQL syntax is correct.
      

      MaxScale logs:

      warning: (3) [dbfwfilter] Query could not be parsed completely and will hence be rejected. Please ensure that the SQL syntax is correct: select id as engine from users WHERE id = 1                        
      

        Attachments

          Activity

            People

            Assignee:
            johan.wikman Johan Wikman
            Reporter:
            disc Alexandr Hacicheant
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Git Integration