OK boss.

My query:

Output :

Code:
SELECT * , 
TIMEDIFF
(
STR_TO_DATE(CONCAT(b.Date, ' ', b.hour), '%Y-%m-%d %H:%i:%S') , 
STR_TO_DATE(CONCAT(a.Date, ' ', a.hour), '%Y-%m-%d %H:%i:%S')
) AS strDiff 
FROM doTbl_A a JOIN
doTbl_A b ON 
a.ID=b.id-1 
WHERE a.DIST=b.DIST 
AND a.DATE=b.DATE ORDER BY a.ID
Output:

Code:
ID = 4
Dist = TE 
Date = 16/10/2009
Hour = 13:24:34
ID = 5
Dist = TE 
Date = 16/10/2009
Hour = 14:11:02
strDiff = 20/10/2009 0.46.28

ID = 5
Dist = TE 
Date = 16/10/2009
Hour = 14:11:02
ID = 6
Dist = TE 
Date = 16/10/2009
Hour = 14:23:47
strDiff = 20/10/2009 0.12.45

ID = 7
Dist = PE 
Date = 16/10/2009
Hour = 17:53:40
ID = 8
Dist = PE 
Date = 16/10/2009
Hour = 19:04:55
strDiff = 20/10/2009 1.11.15
Why in strDiff I have the date and not only the different of the time?