Uploaded image for project: 'Apache Drill'
  1. Apache Drill
  2. DRILL-5649

Drill pushed invalid SQL to SQL Server when trim scalar function used

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.10.0
    • None
    • Storage - JDBC
    • None
    • Drill 1.10
      SQL Server 2016

    Description

      plugin defined to access SQL Server via JDBC

      following statement is sent to Drill which fails due to invalid SQL sent to SQL Server

      select trim(TJOIN1.C2) from certsqlserver.dbo.TJOIN1

      Error: DATA_READ ERROR: The JDBC storage plugin failed while trying setup the SQL query.

      SELECT TRIM(BOTH ' ' FROM "C2") AS "EXPR$0"
      FROM "dbo"."TJOIN1"
      plugin certsqlserver

      https://docs.microsoft.com/en-us/sql/t-sql/functions/trim-transact-sql

      Attachments

        Activity

          People

            Unassigned Unassigned
            the6campbells N Campbell
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: