You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Background: Support for Min/Max/Sum/Count were added for DataType::Timestamp(*) types in apache/arrow#9970.
This ticket tracks adding support for Avg, which is slightly more involved as currently Avg assumes the output type is always F64, and in this case I think Avg(timestamp) should also be (timestamp). We should double check what postgres does in this case and follow its example
Comment from Andrew Lamb(alamb) @ 2021-04-11T09:48:09.161+0000:
[~Dandandan] notes that PostgreSQL doesn't support SUM or AVG for timestamps: https://www.postgresql.org/docs/13/functions-aggregate.html
so perhaps we should not support it in DataFusion either :thinking_face:
Activity
alamb commentedon Apr 26, 2021
Comment from Andrew Lamb(alamb) @ 2021-04-11T09:48:09.161+0000:
waitingkuo commentedon Aug 15, 2022
@alamb
Postgresql has
AVGandSUMfortimebut nottimestampsShould we close this and submit another ticket for
AVG(Time)andSUM(Time)?alamb commentedon Aug 15, 2022
@waitingkuo -- I think that sounds like a good idea. I will do so.
waitingkuo commentedon Aug 15, 2022
@alamb i just tested postgrseql, looks like SUM and AVG cast Time to Interval and then SUM / AVG them
this make sense otherwise SUM(Time) is just quite strange
alamb commentedon Aug 15, 2022
#3166 👍
Run `maturin develop` instead of `cargo build` in verification script (…