Details
Description
Vectorized string dictionary reader cannot differentiate between the case where all dictionary entries are null vs single entry with empty string. This causes wrong results when reading data out of such files.
Vectorization On
SET hive.vectorized.execution.enabled=true;
SET hive.fetch.task.conversion=none;
select vcol from testnullorc3 limit 1;
OK
NULL
Vectorization Off
SET hive.vectorized.execution.enabled=false;
SET hive.fetch.task.conversion=none;
select vcol from testnullorc3 limit 1;
OK
The input table testnullorc3 contains a varchar column vcol with few empty strings and few nulls. For this table, non vectorized reader returns empty as first row but vectorized reader returns NULL.