Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
1.12.2
-
None
Description
Well since we have supported project push-down, some primary-key in original schema may not exist no longer more, so the non-existed column shall be filtered out.
Current code:
val columns = relOptTable.getRowType.getFieldNames val columnIndices = schema.getPrimaryKey.get().getColumns map { c => columns.indexOf(c) }
May be supposed to correct to:
val columns = relOptTable.getRowType.getFieldNames
val columnIndices = schema
.getPrimaryKey
.get()
.getColumns
.map(columns.indexOf)
.filterNot(_ == -1) // filter out the non-exist column
Attachments
Issue Links
- is fixed by
-
FLINK-22157 Join & Select a part of composite primary key will cause ArrayIndexOutOfBoundsException
- Closed