You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "Paul Rogers (JIRA)" <ji...@apache.org> on 2019/03/06 05:19:00 UTC
[jira] [Created] (IMPALA-8287) SHOW CREATE TABLE does not escape
column names
Paul Rogers created IMPALA-8287:
-----------------------------------
Summary: SHOW CREATE TABLE does not escape column names
Key: IMPALA-8287
URL: https://issues.apache.org/jira/browse/IMPALA-8287
Project: IMPALA
Issue Type: Bug
Components: Frontend
Affects Versions: Impala 3.1.0
Reporter: Paul Rogers
Create a table that includes a column called `location`. Issue a SHOW CREATE TABLE command for that table. You will get the sql with the name unquoted. Try to execute that statement. You'll get an error:
{noformat}
Syntax error in line 11:
location STRING,
^
Encountered: LOCATION
Expected: DEFAULT, PRIMARY, IDENTIFIER
{noformat}
Reason: {{LOCATION}} is a SQL reserved word. The implementation of SHOW CREATE TABLE should escape reserved column names. Using the {{ToSqlUtils}} method for that purpose.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org