[ https://issues.apache.org/jira/browse/FLINK-3926?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15289215#comment-15289215 ]
Yijie Shen commented on FLINK-3926: ----------------------------------- Yes, I know the convention of `f` followed by index, but it's a public API so it's arguments will be of any style :) I find this while I was doing table exception clean up, we have this code for field look up: {code} case t: TupleTypeInfo[A] => exprs.zipWithIndex.map { case (UnresolvedFieldReference(name), idx) => (idx, name) case (Alias(UnresolvedFieldReference(origName), name), _) => val idx = t.getFieldIndex(origName) if (idx < 0) { throw new TableException(s"$origName is not a field of type $t") } (idx, name) case _ => throw new TableException( "Field reference expression or alias on field expression expected.") } {code} > Incorrect implementation of getFieldIndex in TupleTypeInfo > ----------------------------------------------------------- > > Key: FLINK-3926 > URL: https://issues.apache.org/jira/browse/FLINK-3926 > Project: Flink > Issue Type: Bug > Components: Core > Affects Versions: 1.0.2 > Reporter: Yijie Shen > Assignee: Yijie Shen > Priority: Minor > > The origin code assumes filed name as *f2* which is not always true. > Finding a field *x* would result in NumberFormatException -- This message was sent by Atlassian JIRA (v6.3.4#6332)