Skip to content
Advertisement

Tag: datetime

How to calculate AVG, MIN & MAX of date interval of a column in a table?

I have a table more like this +—-+————-+———————+ | id | order_id | transaction_date | +—-+————-+———————+ | 1 | TEST000001 | 2018-01-01 00:00:10 | | 2 | TEST000002 | 2018-01-01 00:10:10 | | 3 | TEST000003 | 2018-01-02 03:18:01 | | 4 | TEST000004 | 2018-02-04 05:00:00 | | 5 | TEST000005 | 2018-02-10 16:00:10 | +—-+————-+———————+ There is datetime

Advertisement