Re: DateTime Component that Supports UTC



"Russ Weston" <russ.weston@xxxxxxxxxxx> wrote
Wondering if there is a data-aware DateTime control that reads a database datetime field (stored in UTC format) and displays the value on the screen with respect to the local bias.

Russ,

You can create your own OnGetText handler for the DB field
that has the TDateTime data and add you own local bias correction.

However, I have never found that, by itself, to be useful for historical or future date-times such as are usually stored in a data tables, because the bias values can change over time.

Instead, I prefer to record GMT (a.k.a. UT1 or UT2, but not UTC) *and*, in another field, the local time offset for the point where the date-time applied or applies. Then in the display you can change how your OnGetText event handler controls the correction for bias, using both field, if required.

Regards, JohnH

PS: Microsoft misuses the term "UTC". UT1, UT2, and GMT days have 24 hours, with each hour having 60 minutes, and each minute having 60 seconds, with the seconds synchronized to the rotation of the earth by stretching or compressing their length. UTC time is based on constant length seconds with an occasional 59 or 61 second minute used to synchronize UTC with the rotation of the earth. .



Relevant Pages

  • Re: Truly Offensive Bad Astronomy
    ... longer by the rotation of the Earth. ... For the UTC time scale, the addition or subtraction of Leap Seconds ... the Earth with respect to the Earth-Sun line. ...
    (sci.astro.amateur)
  • Re: Twins paradox debunked and broken down
    ... Atomic clocks are more accurate than the Earth itself is as a clock. ... Remember it happens at midnight UTC so you can do this and still go to ... SERVICE INTERNATIONAL DE LA ROTATION TERRESTRE ET DES SYSTEMES DE REFERENCE ... OBSERVATOIRE DE PARIS ...
    (sci.physics)
  • Re: DateTime Component that Supports UTC
    ... database datetime field and displays the value on the screen with respect to the local bias. ... UTC time is based on constant length seconds with an occasional 59 or 61 second minute used to synchronize UTC with the rotation of the earth. ... I found it interesting that the method did NOT get called when the control that was displaying the data was a TwwDBDateTimePicker (Note: I am using Woll2Woll's InfoPower Studio 2007 controls). ...
    (borland.public.delphi.thirdpartytools.general)
  • Re: Daylight Saving time
    ... local time, with someone having to fix up the clock each time the local ... hardware clock, the time would have to be converted, using the available ... "Modern Unix time is based strictly on UTC. ... the rotation of the Earth. ...
    (uk.comp.os.linux)
  • Jonathans Space Report No. 537
    ... Jonathan's Space Report ... Soyuz TMA-5 docked with the Pirs module on Oct 16 at 0416 UTC. ... (Light travel time to Earth was 1hr 14min so this ... The incoming trajectory was a geocentric orbit of around -1 x ...
    (sci.space.shuttle)