Re:PostgreSQL's Missing DateDiff Function
by castorp on Wednesday December 22, 2021 @02:03AM
(#29646321)
I never understood the need for a datediff function. In Postgres (or Oracle) you just subtract two timestamps and use the resulting interval. It's a different approach to the same problem.
[ Parent
| on HN ]
Re:PostgreSQL's Missing DateDiff Function
by michael-ax on Wednesday December 22, 2021 @06:41AM
(#29648021)
one is counting distance, the other one buckets.
alias the fn name to datebucketdelta to make the different problems memorable individually. :)