It was my mistake when I explained as to what was required.
drop table tab1 purge;
create table tab1(start_time date, end_time date,machines number);
Insert into TAB1
TO_DATE('10/01/2014 14:00:00', 'MM/DD/YYYY HH24:MI:SS'),
TO_DATE('10/01/2014 19:30:00', 'MM/DD/YYYY HH24:MI:SS'),2);
I:SS AM') starttime,
SS AM') endtime from tab1
Now I want the total drive hours end_time minus start_time ( in the format 5.5)
or 4 hour drive as 4
and the hours has to be divided by 2 and always round it down. This number has to be multiplied by no of machines used to draw. Now I get the capacity.
capacity = (hours /2 ) * machines