Daniel Barclay (Drill) created DRILL-3861:
---------------------------------------------

             Summary: Apparent uncontrolled format string error in table name 
error reporting
                 Key: DRILL-3861
                 URL: https://issues.apache.org/jira/browse/DRILL-3861
             Project: Apache Drill
          Issue Type: Bug
          Components: SQL Parser
            Reporter: Daniel Barclay (Drill)


It seems that a data string is being used as a printf format string.

In the following, note the percent character in name of the table file (which 
does not exist, apparently trying to cause an expected no-such-table error) and 
that the actual error mentions format conversion characters:

{noformat}
0: jdbc:drill:zk=local> select * from `test%percent.json`;
Sep 29, 2015 2:59:37 PM org.apache.calcite.sql.validate.SqlValidatorException 
<init>
SEVERE: org.apache.calcite.sql.validate.SqlValidatorException: Table 
'test%percent.json' not found
Sep 29, 2015 2:59:37 PM org.apache.calcite.runtime.CalciteException <init>
SEVERE: org.apache.calcite.runtime.CalciteContextException: From line 1, column 
15 to line 1, column 33: Table 'test%percent.json' not found
Error: SYSTEM ERROR: UnknownFormatConversionException: Conversion = 'p'


[Error Id: 8025e561-6ba1-4045-bbaa-a96cafc7f719 on dev-linux2:31010] 
(state=,code=0)
0: jdbc:drill:zk=local> 
{noformat}

(Selecting SQL Parser component because I _think_ table/file existing is 
checked in validation called in or near the parsing step.)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to