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

Leading / in a select query should be rooted from the workspace rather than from the file system

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 0.4.0
    • None
    • None

    Description

      Lets assume I have a file system with this structure: /opt/drill/touchstone/integer.json
      and I have a workspace "optdrill" rooted at /opt/drill
      If I execute

      select * from `dfs.optdrill`.`touchstone/integer.json`
      or
      select * from `dfs.optdrill`.`./touchstone/integer.json`
      

      then the query runs perfectly fine.
      However, if I lead it with just a slash;

      select * from `dfs.optdrill`.`/touchstone/integer.json
      

      Then the query fails because it is looking for the file "/touchstone/integer.json" rather than "/opt/drill/touchstone/integer.json"
      The expectation is that it should always be rooted at the schema, which is consistent with the show files fix in DRILL-879

      Attachments

        Issue Links

          Activity

            People

              sphillips Steven Phillips
              norrisl Norris Lee
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: