Dan, you can use a negative value in the ADDSec/Min/Hr functions to subtract 
time:

ADDMIN(0:10:00, -5) will give you 5 minutes.

Help says it works with DATETIME so give it a go!

Regards,
Alastair.


  ----- Original Message ----- 
  From: Dan 
  To: RBASE-L Mailing List 
  Sent: Tuesday, April 29, 2008 9:02 PM
  Subject: [RBASE-L] - RE: Need to Add Time to Time



  I guess I still don't get why I can subtract time from time, but not add it. 
  My computed columns work perfectly (or at least, the way I expect)

  TravelTable                        (computed columns)
  column1     column2    column3   column4       column5    column6
  trvestart   jobstart   jobend    traveltime    jobtime    totaltime
  12:47:01    13:35:05   14:45:01  00:48:04      01:09:56   01:58:00

  The computed columns are (RTIME(0,0,(jobstart- travelstart)))

  so subtraction works like I would hope.  
  Why not addition?

  Anyways Guess I need a work around.
  so, at the detail level, I need to convert time to int, then add it and 
convert it back?




  I am not following your example very well.

  At 03:06 PM 4/29/2008, you wrote:

    Set var vTime = (ADDMIN(.vTime,IMIN(.vAddTime)))
     
    Dennis Mcgrath
     

----------------------------------------------------------------------------

    From: [email protected] [ mailto:[EMAIL PROTECTED] On Behalf Of Emmitt Dove
    Sent: Tuesday, April 29, 2008 1:37 PM
    To: RBASE-L Mailing List
    Subject: [RBASE-L] - RE: Need to Add Time to Time
     
    Dan,
     
    Convert the times to (integer) minutes then do the math.
     
    Emmitt Dove
    Manager, DairyPak Business Systems
    Evergreen Packaging, Inc.
    [EMAIL PROTECTED]
    [EMAIL PROTECTED]
    (203) 643-8022
     
    From: [email protected] [ mailto:[EMAIL PROTECTED] On Behalf Of Dan
    Sent: Tuesday, April 29, 2008 2:08 PM
    To: RBASE-L Mailing List
    Subject: [RBASE-L] - Need to Add Time to Time
     

      Hi all,



      Having a bit of trouble adding time to time in a report.

    Tech travels to a job for 30 mins works for 90 mins (both figures come from 
computed columns in the servtimes table.

    Tech      Job      Drive     Jobtime

    Detail section:
    tech1    job1   00:30:00     01:30:00   
    tech2    job1   00:15:00     01:00:00
    tech1    job2   00:45:00     01:00:00
    -------------------------------------
    totals     S/B  01:30:00     03:30:00 

    I can't seem to find a way to compute these totals



    Dan Champion 
     Service Department Manager
    Vredevoogd Heating & Cooling
        Grandville, MI. 49418     
            616-534-8271 x 14
        

    Dan Champion 
   Service Department Manager
  Vredevoogd Heating & Cooling
      Grandville, MI. 49418     
          616-534-8271 x 14
      


------------------------------------------------------------------------------


  No virus found in this incoming message.
  Checked by AVG. 
  Version: 7.5.524 / Virus Database: 269.23.6/1402 - Release Date: 28/04/2008 
13:29

Reply via email to