This is a subtask of
HIVE-5369. In worst case (i.e; absence of column statistics) HIVE-5849 improved the basic statistics with heuristics. But the heuristics failed to provide better estimates in few cases. For example: FILTER operator heuristics did not take into account the number of predicates and if the predicate contains partition column. Also, JOIN estimates were too aggressive and was not user configurable.