On Fri, 13 Jan 2017 03:45:23 -0800 (PST), HansGIS wrote:
> The attribute "dissolve-g" is of the type Integer. The "dissolve-g"
> attribute is NULL for the feature with the ROWID 12.
> When I import the Shapefile into Spatialite it will be converted to
> "0". Shouldn't that be NULL as well?
>
Hi Hans,
you surely know that any shapefile stores its tabular data into a
DBF file: unhappily the baseline dBase-DBF spec does not support
NULL values in any way (NULLs were introduced later by some non
canonical DBF extension, e.g. the ones created by FoxPro, but
this simply adds more chaos to an intrinsically flimsy format).
the sad consequence is that different libraries supporting
the DBF format adopt different interpretations while
encountering unexpected missing / unspecified values.
the specific interpretation adopted by SpatiaLite is strictly
based on the baseline dBase specification, and consequently
any "empty" value will be considered as a ZERO for numeric
columns, and as an empty string ("" - 0 bytes length) for
text columns.
bye Sandro