Details
-
Bug
-
Status: Closed
-
Critical
-
Resolution: Fixed
-
None
Description
SqlMapTypeNameSpec#unparse calls SqlDataTypeSpec#getNullable, and "getNullable" may throw NPE
if (!keyType.getNullable()) { writer.keyword("NOT NULL"); }
See in SqlDataTypeSpec
/** Whether data type allows nulls. * * <p>Nullable is nullable! Null means "not specified". E.g. * {@code CAST(x AS INTEGER)} preserves the same nullability as {@code x}. */ private Boolean nullable;
This API is from calcite, and all callers will determine if it is null: