Good day,

I have a case-class defined like this:

    case class MyClass(ts: Long, s1: String, s2: String, i1: Integer,  i2:
Integer)
    object MyClass {
        val EMPTY = MyClass(0L, null, null, 0, 0)
        def apply(): MyClass = EMPTY
    }

My code has been running fine (I was not aware of the limitation mentioned
in
https://ci.apache.org/projects/flink/flink-docs-stable/dev/types_serialization.html)

But when I tried to create the instance /MyClass(0L, null, null, *null*,
0)/, I got the following error: /org.apache.flink.types.NullFieldException:
Field 3 is null, but expected to hold a value./

I am confused. Why there's the difference between a null String and a null
Integer?

Thanks and regards,
Averell



--
Sent from: http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/

Reply via email to