# Time for reports

Thank you very much. Exactly what I was looking for.

Oleg Tumarkin

-----Original Message-----
From: Todd Caughey [SMTP:caugheyt@...]
Sent: Saturday, March 24, 2001 12:42 PM
To: 'vantage@yahoogroups.com'
Subject: RE: [Vantage] Time for reports

I have not found any built-in formula or combo but the following I keep as
a
notepad file that I can use to cut/paste functions. It is a brute force
method. I usually prefer to break complex functions into parts for easier
debugging and reading but it could be worked into one BIG function. I hope
the text does not wrap to badly in email. Change AM/PM to a or p as
desired.
------text file------
! Conversion of Decimal Time to HH:MM

! DecTime is the starting decimal time to be used
NumHour = NUMERIC(SUBSTRING(STRING(DecTime),1,INDEX(STRING(DecTime),'.')
-
1))
ConvHr = IIF(NumHour > 12,NumHour - 12,NumHour)
Meridiem = IIF(NumHour > 12,'PM','AM')
DecMin = SUBSTRING(STRING(DecTime),INDEX(STRING(DecTime),'.'),6)
ConvMin = 60 * Numeric(DecMin)
ClockTime = STRING(ConvHour,'>9') + ':' + STRING(ConvMin,'99') + Meridiem

! Be sure to set format on converted string fields to 99 (2 pos, no dec, no
sign) for rounding of min.
------end text -------

Todd C.
Harvey Vogel Mfg. Co.

-----Original Message-----
From: Oleg Tumarkin [mailto:otumarkin@...]
Sent: Friday, March 23, 2001 1:32 PM
To: 'vantage@yahoogroups.com'
Subject: [Vantage] Time for reports

Does anybody know how to convert time into 12:59a format from format 24.99
using report builder functions? If so I would like to know how to do it.

Thank you
Oleg Tumarkin
Herker Industries

<http://rd.yahoo.com/M=162801.1342103.2934627.1280005/D=egroupmail/S=170
0007
183:N/A=599088/*http://www.knowledgestorm.com/jump_white.html?c=Yahoo&n=
eLer
Software
Faster

pmai
l/S=1700007183:N/A=599088/rand=845371945>

To access the Files Section of our Yahoo!Group for Report Builder and
Crystal Reports and other 'goodies', please go to:
http://groups.yahoo.com/group/vantage/files/.
<http://groups.yahoo.com/group/vantage/files/.> Note: You must have

Your use of Yahoo! Groups is subject to the Yahoo! Terms of
<http://docs.yahoo.com/info/terms/> Service.

[Non-text portions of this message have been removed]

To access the Files Section of our Yahoo!Group for Report Builder and
Crystal Reports and other 'goodies', please go to:
http://groups.yahoo.com/group/vantage/files/. Note: You must have already

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
Does anybody know how to convert time into 12:59a format from format 24.99
using report builder functions? If so I would like to know how to do it.

Thank you
Oleg Tumarkin
Herker Industries
I think you'll have have to use plain ol' math. I don't know of
any built in function.

Oleg Tumarkin wrote:
>
> Does anybody know how to convert time into 12:59a format from format 24.99
> using report builder functions? If so I would like to know how to do it.
>
> Thank you
> Oleg Tumarkin
> Herker Industries
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
I have not found any built-in formula or combo but the following I keep as a
notepad file that I can use to cut/paste functions. It is a brute force
method. I usually prefer to break complex functions into parts for easier
debugging and reading but it could be worked into one BIG function. I hope
the text does not wrap to badly in email. Change AM/PM to a or p as
desired.
------text file------
! Conversion of Decimal Time to HH:MM

! DecTime is the starting decimal time to be used
NumHour = NUMERIC(SUBSTRING(STRING(DecTime),1,INDEX(STRING(DecTime),'.') -
1))
ConvHr = IIF(NumHour > 12,NumHour - 12,NumHour)
Meridiem = IIF(NumHour > 12,'PM','AM')
DecMin = SUBSTRING(STRING(DecTime),INDEX(STRING(DecTime),'.'),6)
ConvMin = 60 * Numeric(DecMin)
ClockTime = STRING(ConvHour,'>9') + ':' + STRING(ConvMin,'99') + Meridiem

! Be sure to set format on converted string fields to 99 (2 pos, no dec, no
sign) for rounding of min.
------end text -------

Todd C.
Harvey Vogel Mfg. Co.

-----Original Message-----
From: Oleg Tumarkin [mailto:otumarkin@...]
Sent: Friday, March 23, 2001 1:32 PM
To: 'vantage@yahoogroups.com'
Subject: [Vantage] Time for reports

Does anybody know how to convert time into 12:59a format from format 24.99
using report builder functions? If so I would like to know how to do it.

Thank you
Oleg Tumarkin
Herker Industries

<http://rd.yahoo.com/M=162801.1342103.2934627.1280005/D=egroupmail/S=1700007
183:N/A=599088/*http://www.knowledgestorm.com/jump_white.html?c=Yahoo&n=eLer
Faster

l/S=1700007183:N/A=599088/rand=845371945>

To access the Files Section of our Yahoo!Group for Report Builder and
Crystal Reports and other 'goodies', please go to:
http://groups.yahoo.com/group/vantage/files/.
<http://groups.yahoo.com/group/vantage/files/.> Note: You must have

Your use of Yahoo! Groups is subject to the Yahoo! Terms of
<http://docs.yahoo.com/info/terms/> Service.

[Non-text portions of this message have been removed]
Oops! Change ConvHour to be ConvHr in ClockTime function. I tried to
shorten lines in previous message to avoid wrapping and missed the
reference. Test on Meridiem should be >= . Should have stuck with my