.setDistinctValuesCount(rowsPerPartition) .setNullsFraction(0.0) .setAverageRowSize(BIGINT.getFixedSize()) .build()) .build());
.setDistinctValuesCount(rowsPerPartition) .setNullsFraction(0.0) .setAverageRowSize(BIGINT.getFixedSize()) .build()) .build());
@Override public Optional<PlanNodeStatsEstimate> calculate(AssignUniqueId assignUniqueId, StatsProvider statsProvider, Lookup lookup, Session session, TypeProvider types) { PlanNodeStatsEstimate sourceStats = statsProvider.getStats(assignUniqueId.getSource()); return Optional.of(PlanNodeStatsEstimate.buildFrom(sourceStats) .addSymbolStatistics(assignUniqueId.getIdColumn(), SymbolStatsEstimate.builder() .setDistinctValuesCount(sourceStats.getOutputRowCount()) .setNullsFraction(0.0) .setAverageRowSize(BIGINT.getFixedSize()) .build()) .build()); } }
@Override public Optional<PlanNodeStatsEstimate> calculate(AssignUniqueId assignUniqueId, StatsProvider statsProvider, Lookup lookup, Session session, TypeProvider types) { PlanNodeStatsEstimate sourceStats = statsProvider.getStats(assignUniqueId.getSource()); return Optional.of(PlanNodeStatsEstimate.buildFrom(sourceStats) .addSymbolStatistics(assignUniqueId.getIdColumn(), SymbolStatsEstimate.builder() .setDistinctValuesCount(sourceStats.getOutputRowCount()) .setNullsFraction(0.0) .setAverageRowSize(BIGINT.getFixedSize()) .build()) .build()); } }
.distinctValuesCount(2) .nullsFraction(0) .averageRowSize(BIGINT.getFixedSize()))); .distinctValuesCount(1) .nullsFraction(0) .averageRowSize(BIGINT.getFixedSize())));
.distinctValuesCount(2) .nullsFraction(0) .averageRowSize(BIGINT.getFixedSize()))); .distinctValuesCount(1) .nullsFraction(0) .averageRowSize(BIGINT.getFixedSize())));
.distinctValuesCount(2) .nullsFraction(0) .averageRowSize(BIGINT.getFixedSize()))); .distinctValuesCount(1) .nullsFraction(0) .averageRowSize(BIGINT.getFixedSize()))); .distinctValuesCount(10) .nullsFraction(0) .averageRowSize(BIGINT.getFixedSize())));
.distinctValuesCount(2) .nullsFraction(0) .averageRowSize(BIGINT.getFixedSize()))); .distinctValuesCount(1) .nullsFraction(0) .averageRowSize(BIGINT.getFixedSize()))); .distinctValuesCount(10) .nullsFraction(0) .averageRowSize(BIGINT.getFixedSize())));