Re: Sql Everywhere Date precision ?
- From: "Steve B." <steve_beauge@xxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 16 Aug 2006 18:24:02 +0200
thanks for your answer.
As I said, i can simply store the "long" value, the result will be the same.
For your information, I'm building a desktop application, not a mobile
application.
I choose sql everywhere since I do not want to force the user to install sql
express (too big for what I need).
Steve
"Ginny Caughey [MVP]" <ginny.caughey.online@xxxxxxxxxxxxxx> a écrit dans le
message de news: O8xoJJUwGHA.4700@xxxxxxxxxxxxxxxxxxxxxxx
Steve,
From Books Online at
http://msdn2.microsoft.com/en-us/library/ms172424.aspx:
"Date and time data from January 1, 1753, to December 31, 9999, with an
accuracy of one three-hundredth second, or 3.33 milliseconds. Values are
rounded to increments of .000, .003, or .007 milliseconds.
Stored as two 4-byte integers. The first 4 bytes store the number of days
before or after the base date, January 1, 1900. The base date is the
system's reference date. Values for datetime earlier than January 1, 1753,
are not permitted. The other 4 bytes store the time of day represented as
the number of milliseconds after midnight. Seconds have a valid range of
0-59."
I understand your need for precision, but as a practical matter I'm not
sure the clock in mobile devices is as accurate as that anyway.
--
Ginny Caughey
Device Application Development MVP
"Steve B." <steve_beauge@xxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:OCxMW%23TwGHA.4688@xxxxxxxxxxxxxxxxxxxxxxx
Hi,
I'm inserting a date into a sql /e table using a sqlceparameter with the
DateTime db type.
The date's ticks is : Ticks 632902822536718750 long
When I retrieve the same date, I get a Date with this ticks : Ticks
632902822536700000 long
I suppose the datetime format has a precision limitation, right ?
I need such a precision since I'm storing file write time which is quite
precise and I need to compare stored date with actual file date. It's not
a blocking problem (since I can store the long value), but I'd like to
know if there is any way to "raise" the precision of the datetime format.
Thanks in advance,
Steve
.
- Follow-Ups:
- Re: Sql Everywhere Date precision ?
- From: Ginny Caughey [MVP]
- Re: Sql Everywhere Date precision ?
- References:
- Sql Everywhere Date precision ?
- From: Steve B.
- Re: Sql Everywhere Date precision ?
- From: Ginny Caughey [MVP]
- Sql Everywhere Date precision ?
- Prev by Date: Re: Sql Everywhere Date precision ?
- Next by Date: Re: Sql Everywhere Date precision ?
- Previous by thread: Re: Sql Everywhere Date precision ?
- Next by thread: Re: Sql Everywhere Date precision ?
- Index(es):
Relevant Pages
|