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

Create view on Connect TABLE with decimal type column return errors or 0,00... value

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open (View Workflow)
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 10.4.22
    • Fix Version/s: 10.4
    • Labels:
      None
    • Environment:
      Centos 7 Linux

      Description

      When select values on a view with decimal column/s from a Connect table, MariaDB returns error or value filled with 0,00...
      How to reproduce:

      CREATE TABLE test_table (
      `dec_column` decimal(22,8) DEFAULT NULL
      ) ENGINE=CONNECT DEFAULT CHARSET=latin1 CONNECTION='Driver=ODBC Driver 17 for SQL Server;Server=192.168.*.*,1434;Database=DBNAME;UID=sa;PWD=password;connect timeout=3600' `TABLE_TYPE`='ODBC' `TABNAME`='original_table';
       
      CREATE ALGORITHM = UNDEFINED SQL SECURITY DEFINER VIEW `test_view` AS select sql_cache `test_table`.`dec_column` AS `dec_column` from `test_table` ;
       
      SELECT * FROM test_view;
      Result:
      0.00000000
      0.00000000
      0.00000000
      0.00000000
      .......
      

      MariaDB 10.4.21 works without problems.

        Attachments

          Activity

            People

            Assignee:
            bertrandop Olivier Bertrand
            Reporter:
            brainstorm Davide Bonsangue
            Votes:
            0 Vote for this issue
            Watchers:
            2 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.