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

Drill fails to read files that begin with 'u' on Windows

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Not A Bug
    • None
    • None
    • Storage - Text & CSV
    • None

    Description

      It is very easy to reproduce on Windows.

      Just try to run this select. It is not necessary to actually have this folder of file.

      SELECT * FROM dfs.`c:\AnyFolder\udontlikewindo.csv`;

      SQL Error: VALIDATION ERROR: Unable to parse unicode value: dont

      The workaround is to replace "\" with "/" which will work on Windows 10.

      Stack trace:

      {{Caused by: java.lang.IllegalArgumentException: Unable to parse unicode value: dont }}
      {{    at org.apache.commons.lang3.text.translate.UnicodeUnescaper.translate(UnicodeUnescaper.java:59) }}
      {{    at org.apache.commons.lang3.text.translate.AggregateTranslator.translate(AggregateTranslator.java:55) }}
      {{    at org.apache.commons.lang3.text.translate.CharSequenceTranslator.translate(CharSequenceTranslator.java:90) }}
      {{    at org.apache.commons.lang3.text.translate.CharSequenceTranslator.translate(CharSequenceTranslator.java:64) }}
      {{    at org.apache.commons.lang3.StringEscapeUtils.unescapeJava(StringEscapeUtils.java:526) }}
      {{    at org.apache.drill.common.util.DrillStringUtils.unescapeJava(DrillStringUtils.java:55) }}
      {{    at org.apache.drill.exec.store.dfs.FileSelection.create(FileSelection.java:277) }}
      {{    at org.apache.drill.exec.store.dfs.WorkspaceSchemaFactory$WorkspaceSchema$FileSelectionInspector.getFileSelection(WorkspaceSchemaFactory.java:860) }}
      {{    at org.apache.drill.exec.store.dfs.WorkspaceSchemaFactory$WorkspaceSchema$FileSelectionInspector.<init>(WorkspaceSchemaFactory.java:847) }}
      {{    at org.apache.drill.exec.store.dfs.WorkspaceSchemaFactory$WorkspaceSchema.create(WorkspaceSchemaFactory.java:600) }}
      {{    at org.apache.drill.exec.store.dfs.WorkspaceSchemaFactory$WorkspaceSchema.create(WorkspaceSchemaFactory.java:295) }}
      {{    at org.apache.drill.exec.planner.sql.ExpandingConcurrentMap.getNewEntry(ExpandingConcurrentMap.java:96) }}
      {{    at org.apache.drill.exec.planner.sql.ExpandingConcurrentMap.get(ExpandingConcurrentMap.java:90) }}
      {{    at org.apache.drill.exec.store.dfs.WorkspaceSchemaFactory$WorkspaceSchema.getTable(WorkspaceSchemaFactory.java:452) }}
      {{    at org.apache.drill.exec.store.dfs.FileSystemSchemaFactory$FileSystemSchema.getTable(FileSystemSchemaFactory.java:127) }}
      {{    at org.apache.calcite.jdbc.SimpleCalciteSchema.getImplicitTable(SimpleCalciteSchema.java:83) }}
      {{    at org.apache.calcite.jdbc.CalciteSchema.getTable(CalciteSchema.java:289) }}
      {{    at org.apache.calcite.sql.validate.EmptyScope.resolve_(EmptyScope.java:143) }}
      {{    at org.apache.calcite.sql.validate.EmptyScope.resolveTable(EmptyScope.java:99) }}
      {{    at org.apache.calcite.sql.validate.DelegatingScope.resolveTable(DelegatingScope.java:203) }}
      {{    at org.apache.calcite.sql.validate.IdentifierNamespace.resolveImpl(IdentifierNamespace.java:105) }}
      {{    at org.apache.calcite.sql.validate.IdentifierNamespace.validateImpl(IdentifierNamespace.java:177) }}
      {{    at org.apache.calcite.sql.validate.AbstractNamespace.validate(AbstractNamespace.java:84) }}
      {{    at org.apache.calcite.sql.validate.SqlValidatorImpl.validateNamespace(SqlValidatorImpl.java:1009) }}
      {{    at org.apache.calcite.sql.validate.SqlValidatorImpl.validateQuery(SqlValidatorImpl.java:969) }}
      {{    at org.apache.calcite.sql.validate.SqlValidatorImpl.validateFrom(SqlValidatorImpl.java:3129) }}
      {{    at org.apache.drill.exec.planner.sql.conversion.DrillValidator.validateFrom(DrillValidator.java:80) }}
      {{    at org.apache.calcite.sql.validate.SqlValidatorImpl.validateFrom(SqlValidatorImpl.java:3111) }}
      {{    at org.apache.drill.exec.planner.sql.conversion.DrillValidator.validateFrom(DrillValidator.java:80) }}
      {{    at org.apache.calcite.sql.validate.SqlValidatorImpl.validateSelect(SqlValidatorImpl.java:3383) }}
      {{    at org.apache.calcite.sql.validate.SelectNamespace.validateImpl(SelectNamespace.java:60) }}
      {{    at org.apache.calcite.sql.validate.AbstractNamespace.validate(AbstractNamespace.java:84) }}
      {{    at org.apache.calcite.sql.validate.SqlValidatorImpl.validateNamespace(SqlValidatorImpl.java:1009) }}
      {{    at org.apache.calcite.sql.validate.SqlValidatorImpl.validateQuery(SqlValidatorImpl.java:969) }}
      {{    at org.apache.calcite.sql.SqlSelect.validate(SqlSelect.java:216) }}
      {{    at org.apache.calcite.sql.validate.SqlValidatorImpl.validateScopedExpression(SqlValidatorImpl.java:944) }}
      {{    at org.apache.calcite.sql.validate.SqlValidatorImpl.validate(SqlValidatorImpl.java:651) }}
      {{    at org.apache.drill.exec.planner.sql.conversion.SqlConverter.validate(SqlConverter.java:190) }}
      {{    at org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.validateNode(DefaultSqlHandler.java:647) }}
      {{    at org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.validateAndConvert(DefaultSqlHandler.java:195) }}
      {{    at org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.getPlan(DefaultSqlHandler.java:169) }}
      {{    at org.apache.drill.exec.planner.sql.DrillSqlWorker.getQueryPlan(DrillSqlWorker.java:283) }}
      {{    at org.apache.drill.exec.planner.sql.DrillSqlWorker.getPhysicalPlan(DrillSqlWorker.java:163) }}
      {{    at org.apache.drill.exec.planner.sql.DrillSqlWorker.convertPlan(DrillSqlWorker.java:140) }}
      {{    at org.apache.drill.exec.planner.sql.DrillSqlWorker.getPlan(DrillSqlWorker.java:93) }}
      {{    at org.apache.drill.exec.work.foreman.Foreman.runSQL(Foreman.java:593) }}
      {{    at org.apache.drill.exec.work.foreman.Foreman.run(Foreman.java:274) }}
      {{    at .......(:0) }}
      {{Caused by: java.lang.NumberFormatException: For input string: "dont" under radix 16 }}
      {{    at .......(:0) }}
      {{    at org.apache.commons.lang3.text.translate.UnicodeUnescaper.translate(UnicodeUnescaper.java:56) }}
          ... 47 more

       

       

       

      Attachments

        Activity

          People

            Unassigned Unassigned
            pseudomo pseudomo
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: