Support for null values

I modified some functions in order to allow null values in some data records.