[
https://issues.apache.org/jira/browse/HIVE-22311?focusedWorklogId=338247&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-338247
]
ASF GitHub Bot logged work on HIVE-22311:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 04/Nov/19 17:57
Start Date: 04/Nov/19 17:57
Worklog Time Spent: 10m
Work Description: jcamachor commented on pull request #821: HIVE-22311
URL: https://github.com/apache/hive/pull/821#discussion_r342187541
##########
File path:
ql/src/java/org/apache/hadoop/hive/ql/metadata/formatting/JsonMetaDataFormatter.java
##########
@@ -338,6 +338,19 @@ private ColumnStatisticsData getStatistics(FieldSchema
column, List<ColumnStatis
if (statistics.getDateStats().isSetNumDVs()) {
result.put("distinctCount", statistics.getDateStats().getNumDVs());
}
+ } else if (statistics.isSetTimestampStats()) {
+ if (statistics.getTimestampStats().isSetLowValue()) {
+ result.put("min",
MetaDataFormatUtils.convertToString(statistics.getTimestampStats().getLowValue()));
+ }
+ if (statistics.getTimestampStats().isSetHighValue()) {
+ result.put("max",
MetaDataFormatUtils.convertToString(statistics.getTimestampStats().getHighValue()));
+ }
+ if (statistics.getTimestampStats().isSetNumNulls()) {
+ result.put("numNulls", statistics.getTimestampStats().getNumNulls());
+ }
+ if (statistics.getTimestampStats().isSetNumDVs()) {
+ result.put("distinctCount",
statistics.getTimestampStats().getNumDVs());
Review comment:
I have done that for the column stats method. There are still many other
constants values spread in that class that should be moved into constants too.
I will create a follow-up for that.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 338247)
Time Spent: 0.5h (was: 20m)
> Propagate min/max column values from statistics to the optimizer for
> timestamp type
> -----------------------------------------------------------------------------------
>
> Key: HIVE-22311
> URL: https://issues.apache.org/jira/browse/HIVE-22311
> Project: Hive
> Issue Type: Bug
> Components: Statistics
> Reporter: Jesus Camacho Rodriguez
> Assignee: Jesus Camacho Rodriguez
> Priority: Major
> Labels: pull-request-available
> Attachments: HIVE-22311.01.patch, HIVE-22311.01.patch,
> HIVE-22311.02.patch, HIVE-22311.03.patch, HIVE-22311.patch
>
> Time Spent: 0.5h
> Remaining Estimate: 0h
>
> Currently stats annotation does not consider timestamp type e.g. for
> estimates with range predicates.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)