-
Type:
Bug
-
Status: Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 1.12.0, 1.11.2
-
Fix Version/s: 1.11.2
-
Component/s: Table SQL / API
-
Labels:
For query
create view tmp_view as select * from ( select f0, row_number() over (partition by f0 order by f0 desc) as rowNum from source) -- the query would be aliased as "EXPR$1" where rowNum = 1
When validation, the inner query would have alias assigned by the system with prefix "EXPR$1", when in the `Expander`, we replace the id in the inner query all with this prefix which is wrong because we do not add the alias to the inner query anymore.
To solve the problem, skip the expanding of id with "EXPR$" just like how SqlUtil#deriveAliasFromOrdinal added it.
This was introduced by FLINK-18750.
- is caused by
-
FLINK-18750 SqlValidatorException thrown when select from a view which contains a UDTF call
-
- Closed
-
- links to