druid-io / pydruid

A Python connector for Druid
Other
506 stars 194 forks source link

Added support for "expression" in aggregators #109

Open jeremyborg opened 6 years ago

jeremyborg commented 6 years ago

If numeric data is stored as String, one will not be able to perform aggregations on it. This fix provides a solution to this problem. Example: aggregations={"total": expression("amount", "doubleSum")}, will perform doubleSum on the "amount" field and return the result as "total"