@malloydata/malloy 0.0.234-dev250204162601 → 0.0.234-dev250205222325
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -179,7 +179,7 @@ class SnowflakeDialect extends dialect_1.Dialect {
|
|
|
179
179
|
sqlSumDistinct(key, value, funcName) {
|
|
180
180
|
const hashKey = this.sqlSumDistinctHashedKey(key);
|
|
181
181
|
const scale = 100000000.0;
|
|
182
|
-
const v = `(COALESCE(${value},0)*${scale})`;
|
|
182
|
+
const v = `(CAST (COALESCE(${value},0)*${scale} as INT))`;
|
|
183
183
|
const sqlSum = `(SUM(DISTINCT ${hashKey} + ${v}) - SUM(DISTINCT ${hashKey}))/${scale}`;
|
|
184
184
|
if (funcName === 'SUM') {
|
|
185
185
|
return sqlSum;
|