snuyanzin commented on code in PR #27907:
URL: https://github.com/apache/flink/pull/27907#discussion_r3067920920


##########
flink-table/flink-table-planner/src/main/java/org/apache/flink/table/planner/operations/converters/SqlNodeConvertUtils.java:
##########
@@ -87,7 +87,7 @@ static CatalogView toCatalogView(
                 context.getSqlValidator().getNamespace(validateQuery);
         validateDuplicatedColumnNames(validateQuery, viewFields, 
validatedNamespace);
 
-        String expandedQuery = context.toQuotedSqlString(validateQuery);
+        String expandedQuery = context.expandSqlIdentifiers(originalQuery);

Review Comment:
   ideally we should keep it as is as it gives fully expanded sql and 
`expandSqlIdentifiers` doesn't do that  (for instance it doesn't expand star).
   
   I tend to think that rather than fixing here  it should be fixed in Calcite
   for more details look at https://issues.apache.org/jira/browse/CALCITE-7465, 
https://issues.apache.org/jira/browse/CALCITE-7466, 
https://issues.apache.org/jira/browse/CALCITE-7467, probably something else



-- 
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]

Reply via email to