I have track records of a truck in a table.
===================================================== ====
This example up there I have 5 records that I picked up in the table by checking Speed > 0 Records 1 through 3 show that it is sequential. There was a pause and the truck returned 2 hours later.
If I add up the time in the SQL query it will give that it worked 1 day, 2 hours and a few seconds. When in fact it was 30 seconds (1 to 3). And had 2 more starts on the 30th (nº 4) and the 31st on the 5th.
How do I get the total amount of hours or seconds worked? Note The table has more than 500,000 records. I wanted to get the amount of