shounakmk219 commented on code in PR #12591:
URL: https://github.com/apache/pinot/pull/12591#discussion_r1532143608
##########
pinot-query-planner/src/main/java/org/apache/pinot/query/planner/logical/RelToPlanNodeConverter.java:
##########
@@ -287,7 +294,12 @@ public static Set<String> getTableNamesFromRelRoot(RelNode
relRoot) {
// Calcite encloses table and schema names in square brackets to
properly quote and delimit them in SQL
// statements, particularly to handle cases when they contain special
characters or reserved keywords.
String tableName = qualifiedTableName.replaceAll("^\\[(.*)\\]$", "$1");
- tableNames.add(tableName);
+ String[] split = tableName.split(", ");
+ if (split.length == 1) {
+ tableNames.add(tableName);
+ } else {
+ tableNames.add(DatabaseUtils.translateTableName(split[1], split[0]));
Review Comment:
`RelOptUtil.findAllTableQualifiedNames` returns the table name in the format
`[foo, bar]` for a table `foo.bar` hence the split on `', '`
--
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]