(expression: SQLWrapper)
| 97 | * @see sum to get the sum of all non-null values in `expression`, including duplicates |
| 98 | */ |
| 99 | export function sumDistinct(expression: SQLWrapper): SQL<string | null> { |
| 100 | return sql`sum(distinct ${expression})`.mapWith(String); |
| 101 | } |
| 102 | |
| 103 | /** |
| 104 | * Returns the maximum value in `expression`. |
no test coverage detected