Gopal V created HIVE-4757:
-----------------------------
Summary: LazyTimestamp goes into irretrievable NULL mode once
inited with NULL once
Key: HIVE-4757
URL: https://issues.apache.org/jira/browse/HIVE-4757
Project: Hive
Issue Type: Bug
Reporter: Gopal V
The LazyTimestamp.init() code turns into a NULL generator after parsing the
very first NULL value (or format error).
The code is as follows
{code}
Timestamp t = null;
if (s.compareTo("NULL") == 0) {
isNull = true;
logExceptionMessage(bytes, start, length, "TIMESTAMP");
} else {
try {
t = Timestamp.valueOf(s);
} catch (IllegalArgumentException e) {
isNull = true;
logExceptionMessage(bytes, start, length, "TIMESTAMP");
}
}
{code}
As might be obvious from the code above, the class does not reset the isNull to
false when a parse is successful.
So if by any reason, it is initialized with a NULL value, the
LazyTimestamp.getObject() will always return NULL for all further rows.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira