Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ public SnowflakeClient(
.add(new ImplementCountAll(bigintTypeHandle))
.add(new ImplementCount(bigintTypeHandle))
.add(new ImplementMinMax(false))
.add(new ImplementSum(SnowflakeClient::toTypeHandle))
.add(new ImplementSum(SnowflakeClient::decimalTypeHandle))
.add(new ImplementAvgFloatingPoint())
.add(new ImplementAvgDecimal())
.add(new ImplementAvgBigint())
Expand Down Expand Up @@ -267,9 +267,15 @@ public boolean supportsAggregationPushdown(ConnectorSession session, JdbcTableHa
return preventTextualTypeAggregationPushdown(groupingSets);
}

private static Optional<JdbcTypeHandle> toTypeHandle(DecimalType decimalType)
private static Optional<JdbcTypeHandle> decimalTypeHandle(DecimalType decimalType)
{
return Optional.of(new JdbcTypeHandle(Types.NUMERIC, Optional.of("decimal"), Optional.of(decimalType.getPrecision()), Optional.of(decimalType.getScale()), Optional.empty(), Optional.empty()));
return Optional.of(new JdbcTypeHandle(
Types.NUMERIC,
Optional.of("NUMBER"),
Optional.of(decimalType.getPrecision()),
Optional.of(decimalType.getScale()),
Optional.empty(),
Optional.empty()));
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -222,13 +222,6 @@ public void testDistinctAggregationPushdown()
abort("TODO");
}

@Test
@Override
public void testNumericAggregationPushdown()
{
abort("TODO");
}

@Test
@Override
public void testInsertIntoNotNullColumn()
Expand Down