impala-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alex Behm (Code Review)" <ger...@cloudera.org>
Subject [Impala-ASF-CR] IMPALA-4418: Extra blank lines in query result
Date Thu, 15 Jun 2017 04:23:58 GMT
Alex Behm has posted comments on this change.

Change subject: IMPALA-4418: Extra blank lines in query result
......................................................................


Patch Set 3:

(5 comments)

http://gerrit.cloudera.org:8080/#/c/7055/3//COMMIT_MSG
Commit Message:

Line 11: that returns 0 row.
This change avoids printing blank lines when the Impala shell fetches 0 rows from a statement.


http://gerrit.cloudera.org:8080/#/c/7055/3/shell/impala_shell.py
File shell/impala_shell.py:

Line 922:           # IMPALA-4418: Breaking out of the loop to prevent an empty newline printing
Break out of the loop to prevent printing an unnecessary empty line.

(the rest is clear from the code context)


http://gerrit.cloudera.org:8080/#/c/7055/3/tests/shell/test_shell_interactive.py
File tests/shell/test_shell_interactive.py:

Line 293:     # IMPALA-4418
We use this format

# IMPALA-4418: DROP AND USE ...
# ...
# ...


Line 294:     # DROP and USE are exception cases that client does not fetch.
DROP and USE are generally exceptional statements where the client does not fetch. However,
when preceded by a comment, the Impala shell treats them like any other statement and will
try to fetch - receiving 0 rows. For statements returning 0 rows we do not want an empty line
in stdout.


Line 296:     # CREATE [DATABASE|TABLE] should trigger a 0 row fetch
Remove this part about CREATE in favor of the more general formulation above.

Maybe add another test that does not require create, e.g.:
select * from functional.alltypes limit 0


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I6e18ce36be07ee90a16b007b1e30d5255ef8a839
Gerrit-PatchSet: 3
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-Owner: Vincent Tran <vttran@cloudera.com>
Gerrit-Reviewer: Alex Behm <alex.behm@cloudera.com>
Gerrit-Reviewer: Vincent Tran <vttran@cloudera.com>
Gerrit-HasComments: Yes

Mime
View raw message