They're great functions the ADD - sec, min, hour, day, etc.

They work with minus numbers, too, so you can subtract as well:
(AddSec(0:00:00, -59))

Regards,
Alastair.

--------------------------------------------------
From: "David Fowler" <[email protected]>
Sent: Wednesday, July 07, 2010 8:28 PM
To: "RBASE-L Mailing List" <[email protected]>
Subject: [RBASE-L] - Re: converting real to time format

Alastair,

Thanks, that worked for what I'm trying to do.

David

-----Original Message-----
From: [email protected] [mailto:[email protected]]on Behalf Of Alastair
Burr
Sent: Tuesday, July 06, 2010 5:53 PM
To: RBASE-L Mailing List
Subject: [RBASE-L] - Re: converting real to time format


Try this but watch out if you change days, that is, go past midnight:

set var vStart time = 14:00:00
set var vEnd time = 18:00:00
set var vElapsed time = (AddSec(0:00:00, (vEnd - vStart) ))

show var vElapsed


If you are going over a date change then:

set var vStartdt datetime = '20/06/2010 14:00:00'
set var vEnddt datetime = '21/06/2010 13:00:00'
set var vElapsed time = (AddSec(0:00:00, (vEnddt - vStartdt) ))

show var vElapsed


Regards,
Alastair.






No virus found in this incoming message.
Checked by AVG - www.avg.com
Version: 9.0.830 / Virus Database: 271.1.1/2987 - Release Date: 07/07/10 07:36:00


--- RBASE-L
================================================
TO POST A MESSAGE TO ALL MEMBERS:
Send a plain text email to [email protected]

(Don't use any of these words as your Subject:
INTRO, SUBSCRIBE, UNSUBSCRIBE, SEARCH,
REMOVE, SUSPEND, RESUME, DIGEST, RESEND, HELP)
================================================
TO SEE MESSAGE POSTING GUIDELINES:
Send a plain text email to [email protected]
In the message SUBJECT, put just one word: INTRO
================================================
TO UNSUBSCRIBE: Send a plain text email to [email protected]
In the message SUBJECT, put just one word: UNSUBSCRIBE
================================================
TO SEARCH ARCHIVES:
Send a plain text email to [email protected]
In the message SUBJECT, put just one word: SEARCH-n
(where n is the number of days). In the message body, place any text to search for.
================================================


Reply via email to