I am using the following powrbuilder code
if DaysAfter(startdate,enddat
ld_time_duration=SecondsAf
ld_total_duration = ld_time_duration
end if
long pos_of_decimal , hours
decimal minutes
string s_total_time
pos_of_decimal = pos ( string ( ld_time_duration) ,'.' )
hours= LONG ( mid (string ( ld_time_duration ) , 1, pos_of_decimal - 1) )
minutes = truncate ( dec ( mid ( string ( ld_time_duration ) , pos_of_decimal , 2) ) * 60 , 0)
s_total_time = string ( hours) + ':' + string(minutes)
Main Topics
Browse All Topics





by: sujith80Posted on 2007-12-07 at 03:28:09ID: 20426655
How are you calculating the time difference in your code?
I am getting 57 mins with the following expression.
select round( ( to_date('1-1-07 02:57', 'dd-mm-yy hh24:MI') - to_date('1-1-07 02:00', 'dd-mm-yy hh24:MI')) * 24 * 60)
from dual
/