$query=("SELECT sifra, ((SELECT SUM(time_to_sec(timestamp)) FROM names WHERE reason='2' AND sifra='$id' GROUP BY (sifra)) - (SELECT SUM(time_to_sec(timestamp))....This is not entire query but I dont want to hear OMG :)), stuff any more, whell it works, but I had to use time_to_sec to get true secundes passed away but now I would like to format it to followin:format output I mean :), mysql> SELECT SEC_TO_TIME(2378); -> '00:39:38'mysql> SELECT SEC_TO_TIME(2378) + 0; -> 3938but whatever I pass as argument I do not get correct format out.Whell if any ideas thanks.,