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

CSV file without headers: "SELECT a" fails, "SELECT columns, a" succeeds

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 1.10.0
    • None
    • Storage - Text & CSV
    • None

    Description

      Consider the case discussed in DRILL-5554. Do exactly the same setup, but with a slightly different query. The results are much different.

      Create a CSV file without headers:

      10,foo,bar
      

      Use a CSV storage plugin configured to not skip the first line and not read headers.

      Then, issue the following query:

      SELECT columns, a FROM `dfs.data.example.csv`
      

      Result:

      columns,a
      ["10","foo","bar"],null
      

      Schema:

      columns(VARCHAR:REPEATED), 
      a(INT:OPTIONAL)
      

      Since the query in DRILL-5554 fails:

      SELECT a FROM ...
      

      Expected the query described here to also fail, for a similar reason.

      Attachments

        Activity

          People

            Unassigned Unassigned
            paul-rogers Paul Rogers
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: