drill-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daniel Barclay (Drill) (JIRA)" <j...@apache.org>
Subject [jira] [Created] (DRILL-3136) Binary string literal spaces rejected
Date Mon, 18 May 2015 20:03:00 GMT
Daniel Barclay (Drill) created DRILL-3136:
---------------------------------------------

             Summary: Binary string literal spaces rejected
                 Key: DRILL-3136
                 URL: https://issues.apache.org/jira/browse/DRILL-3136
             Project: Apache Drill
          Issue Type: Bug
            Reporter: Daniel Barclay (Drill)


Spaces allowed by standard SQL's grammar in binary string literals are rejected:

{noformat}
0: jdbc:drill:zk=local> SELECT X'0F 0F' FROM INFORMATION_SCHEMA.CATALOGS;
May 18, 2015 12:55:21 PM org.apache.calcite.sql.validate.SqlValidatorException <init>
SEVERE: org.apache.calcite.sql.validate.SqlValidatorException: Binary literal string must
contain only characters '0' - '9', 'A' - 'F'
May 18, 2015 12:55:21 PM org.apache.calcite.runtime.CalciteException <init>
SEVERE: org.apache.calcite.runtime.CalciteContextException: From line 1, column 8 to line
1, column 15: Binary literal string must contain only characters '0' - '9', 'A' - 'F'
Error: PARSE ERROR: Binary literal string must contain only characters '0' - '9', 'A' - 'F'


[Error Id: 5e09f9b2-2029-4d83-9b3e-048ac5fdcad1 on dev-linux2:31010] (state=,code=0)
0: jdbc:drill:zk=local> 
{noformat}

ISO-8075:2011 Part 2's section 5.3 ("<literal>") says:

{noformat}
<binary string literal> ::=
  X <quote> [ <space>... ] [ { <hexit> [ <space>... ] <hexit>
[ <space>... ] }... ] <quote>
      [ { <separator> <quote> [ <space>... ] [ { <hexit> [ <space>...
]
      <hexit> [ <space>... ] }... ] <quote> }... ]

<hexit> ::=
    <digit> | A | B | C | D | E | F | a | b | c | d | e | f
{noformat}




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

Mime
View raw message