aturoczy commented on code in PR #5005:
URL: https://github.com/apache/hive/pull/5005#discussion_r1454088170
##########
hplsql/src/main/java/org/apache/hive/hplsql/Stmt.java:
##########
@@ -957,7 +957,11 @@ public Integer
forCursor(HplsqlParser.For_cursor_stmtContext ctx) {
int cols = query.columnCount();
Row row = new Row();
for (int i = 0; i < cols; i++) {
- row.addColumnDefinition(query.metadata().columnName(i),
query.metadata().columnTypeName(i));
+ String columnName = query.metadata().columnName(i);
+ if (columnName.contains(".")) {
+ columnName = columnName.substring(columnName.lastIndexOf('.') + 1);
Review Comment:
Just try to be a stupid engineer?
How about table like
col1.
col2...
col3.tab1.nice
I would add negative tests as well.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]