# Time Sum in the format 00:00:00

Hi ABAP Guru's,

I need to find the sum of time units in my internal table.

the data i get from the database is in the format 02 :50:00 and 03:00:00 like wise.

i have to add all the enteries for the same to show the talal number of hr and mint. as 05:50:00 in the internal table.

Plz help me out in the problem......Points fully ensured..

Regards...

Lakhan..

##### Tags:

##### Guest replied

Hi Lakhan,

Check this sample code

This is one way(cumbersome) to obtain the result

REPORT ztest. DATA: w_time1 type sy-uzeit value '025000', w_time2 type sy-uzeit value '030000', w_result type sy-uzeit, w_int1 type i, w_int2 type i. w_int1 = w_time1. w_int2 = w_time2. w_int1 = w_int1 + w_int2. w_result+0(2) = floor( w_int1 / 3600 ). w_result+2(2) = floor( ( w_int1 MOD 3600 ) / 60 ). w_result+4(2) = ( w_int1 MOD 3600 ) MOD 60. write:w_result.