Github user fhueske commented on a diff in the pull request:

    https://github.com/apache/flink/pull/4479#discussion_r132690201
  
    --- Diff: 
flink-libraries/flink-table/src/main/scala/org/apache/flink/table/codegen/CodeGenerator.scala
 ---
    @@ -1172,6 +1172,13 @@ abstract class CodeGenerator(
         val resultTypeTerm = primitiveTypeTermForTypeInfo(fieldType)
         val defaultValue = primitiveDefaultValue(fieldType)
     
    +    // the initial value for result.
    +    val initValue = fieldType match {
    --- End diff --
    
    I had to fix the same issue for FLINK-7337 in PR #4488: 
https://github.com/apache/flink/pull/4488/files#diff-e05ff53adcc1407715fe09572ee092e0L1196
    
    I don't think we need this `initValue`. Especially, we should not introduce 
a special case for `String`. The problem with `String` was a buggy 
implementation of `concat` that did not respect the `isNull` field but relied 
on `resultTerm == null`. I fix this issue in my PR so, we can avoid the special 
case for `String` here.



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to