-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Labels
Description
if allowNullTimeValue is set to true, pinot fills in the System.currentMillis timestamp in place of nulls. This happens in the following piece of code in NullValueTransformer class
// handle null value in time column
if (_defaultTimeValueFormat != null && record.getValue(_dateTimeFieldSpec.getName()) == null) {
String timeValueStr = _defaultTimeValueFormat.fromMillisToFormat(System.currentTimeMillis());
Object timeValue = _dateTimeFieldSpec.getDataType().convert(timeValueStr);
record.putDefaultNullValue(_dateTimeFieldSpec.getName(), timeValue);
}This default value however creates an unpredictable behaviour from querying perspective. e.g. I inserted data for duration from year 2016 to 2018 but suddenly I find there is a timestamp for year 2022 in my data.
Another scenario is where I re-insert my data after clearing the table and find totally different values.
Pinot either needs to set this value to Epoch 0 or move on to some better default.
Reactions are currently unavailable