nictownsend commented on code in PR #27907:
URL: https://github.com/apache/flink/pull/27907#discussion_r3078368087
##########
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:
Hi both - thanks for the discussion and clarification.
> for short term we could consider rolling it back, however so far nobody
was heavily complaining that hot fix is urgently required. In this case I think
we still have time to fix it in a proper way
I tend to build my SQL as a series of views, making it more composable and
easier to read. E.g (pseudo):
```sql
CREATE TABLE source_1:
CREATE TABLE source_2;
CREATE TEMPORARY VIEW joined as (source_1 JOIN source_2);
CREATE TEMPORARY_VIEW matches as (joined MATCH_RECOGNIZE);
CREATE TABLE sink_1;
CREATE TABLE sink_1;
INSERT into sink_1 select * from matches;
INSERT into sink_2 select * from matches WHERE x=y;
```
Are there other ways to achieve the same effect without this bug being
fixed? My concern is that I now have to write (pseduo):
```sql
CREATE TABLE source_1:
CREATE TABLE source_2;
CREATE TABLE sink_1;
CREATE TABLE sink_2;
INSERT into sink_1 select * from (source_1 JOIN source_1) MATCH_RECOGNIZE;
INSERT into sink_2 select * from ((source_1 JOIN source_1) MATCH_RECOGNIZE)
WHERE x=y;
```
--
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]