Github user manishnalla1994 commented on a diff in the pull request:
https://github.com/apache/carbondata/pull/2708#discussion_r216908025
--- Diff:
core/src/main/java/org/apache/carbondata/core/scan/executor/impl/AbstractQueryExecutor.java
---
@@ -383,8 +383,9 @@ private void
fillBlockletInfoToTableBlock(List<TableBlockInfo> tableBlockInfos,
blockletInfo.getBlockletIndex().getMinMaxIndex().getMaxValues());
// update min and max values in case of old store for measures as
min and max is written
// opposite for measures in old store ( store <= 1.1 version)
+ byte[][] tempMaxValues = maxValues;
maxValues = CarbonUtil.updateMinMaxValues(fileFooter, maxValues,
minValues, false);
- minValues = CarbonUtil.updateMinMaxValues(fileFooter, maxValues,
minValues, true);
+ minValues = CarbonUtil.updateMinMaxValues(fileFooter, tempMaxValues,
minValues, true);
--- End diff --
The maxValues are changed in line 386 and we need the old values of
maxValues to compute the correct minValues. So stored it in a temporary
variable first.
---