Can't you take the max value length and use that to format your
calculated time, zero filling, then take the left most 10 characters and
multiply that by 1?  Like Kevin said, it really depends on what you're
ultimately looking for.

BobW
 

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Kevin King
Sent: Tuesday, September 12, 2006 1:45 PM
To: [email protected]
Subject: RE: [U2] Time/Date as a single number

>My method is take date()*86400+time()

Is the goal to track a chronology via a single field? If so, I'd say
your calulation is close.  Wouldn't it be:

((DATE() - 1) * 86500) + TIME()

(...as the number of days elapsed is today - 1, not today.)

Regardless, you're right that the date could get humongous.  For the
cycles you're going through to do this calculation it would be a small
step to convert it into and out of any other base to compress and
decompress the bytes.

The foundational question, however, is one of context.  Why do you
need this?  That answer may limit or expand your options.

-Kevin
[EMAIL PROTECTED]
http://www.PrecisOnline.com
 
** Check out scheduled Connect! training courses at
http://www.PrecisOnline.com/train.html.
-------
u2-users mailing list
[email protected]
To unsubscribe please visit http://listserver.u2ug.org/
-------
u2-users mailing list
[email protected]
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to