Answer by Lennart - Slava Ukraini for mysql - sum interval dates
You could merge overlapping intervals and count the hours from there (untested):select name, min(start), end from ( select x.name, x.start, min(y.end) as end from t as x join t as y on x.name = y.name...
View ArticleAnswer by Mark for mysql - sum interval dates
Consider generating a table of hours as timestamps:HOUR----2014-10-22 12:002014-10-22 13:002014-10-22 14:002014-10-22 15:00...Then you can select the hours that are between the periods of your original...
View Articlemysql - sum interval dates
I would like to sum the hours for each name, giving a total interval between START and END activities. It would be simple if I could subtract from each record the end of the beginning. For example,...
View Article
More Pages to Explore .....