Alex Behm has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/9788 )

Change subject: IMPALA-6719: Reset metadata database name case sensitivity
......................................................................


Patch Set 1:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/9788/1/fe/src/main/java/org/apache/impala/analysis/ResetMetadataStmt.java
File fe/src/main/java/org/apache/impala/analysis/ResetMetadataStmt.java:

http://gerrit.cloudera.org:8080/#/c/9788/1/fe/src/main/java/org/apache/impala/analysis/ResetMetadataStmt.java@60
PS1, Line 60: db.toLowerCase()
> I like introducing new DbName since it's pretty consistent with TableName a
In general, toSql() represents SQL of an analyzed statement where all entities 
and databases have been resolved. It's not required that toSql() preserves the 
user input exactly. In fact, it would often be wrong to do that, think

create view v as select * from T;

Before creating the view we need to resolve "t" and fully qualify it. The 
toSql() of the SelectStmt will output something like:

SELECT * from default.t

Notice how casing has changed in various places, and now "t" is fully qualified.



--
To view, visit http://gerrit.cloudera.org:8080/9788
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Id880aa559cec0afe8fbb7d33ccce83f7b5e474cb
Gerrit-Change-Number: 9788
Gerrit-PatchSet: 1
Gerrit-Owner: Fredy Wijaya <[email protected]>
Gerrit-Reviewer: Alex Behm <[email protected]>
Gerrit-Reviewer: Fredy Wijaya <[email protected]>
Gerrit-Reviewer: Vuk Ercegovac <[email protected]>
Gerrit-Comment-Date: Tue, 27 Mar 2018 00:38:07 +0000
Gerrit-HasComments: Yes

Reply via email to