Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>It looks like the Windows time zone information doesn't match what I'd have expected via TZDB. Here's a program using <a href="http://noda-time.googlecode.com" rel="nofollow">Noda Time</a> to show all the transitions between ~1960 and 1965 with both the BCL TimeZoneInfo (wrapped) and the TZDB 2012i data:</p> <pre><code>using System; using NodaTime; class Test { static void Main() { var bcl = DateTimeZoneProviders.Bcl["Eastern Standard Time"]; var tzdb = DateTimeZoneProviders.Tzdb["America/New_York"]; ShowTransitions(bcl); ShowTransitions(tzdb); } static void ShowTransitions(DateTimeZone zone) { Console.WriteLine("Transitions for {0}", zone.Id); Instant start = Instant.FromUtc(1960, 1, 1, 0, 0); Instant end = Instant.FromUtc(1965, 1, 1, 0, 0); var interval = zone.GetZoneInterval(start); while (interval.Start &lt; end) { Console.WriteLine(interval.Start); interval = zone.GetZoneInterval(interval.End); } Console.WriteLine(); } } </code></pre> <p>Output:</p> <pre><code>Transitions for Eastern Standard Time 1959-10-25T06:00:00Z 1960-04-03T07:00:00Z 1960-10-30T06:00:00Z 1961-04-02T07:00:00Z 1961-10-29T06:00:00Z 1962-04-01T07:00:00Z 1962-10-28T06:00:00Z 1963-04-07T07:00:00Z 1963-10-27T06:00:00Z 1964-04-05T07:00:00Z 1964-10-25T06:00:00Z Transitions for America/Toronto 1959-10-25T06:00:00Z 1960-04-24T07:00:00Z 1960-10-30T06:00:00Z 1961-04-30T07:00:00Z 1961-10-29T06:00:00Z 1962-04-29T07:00:00Z 1962-10-28T06:00:00Z 1963-04-28T07:00:00Z 1963-10-27T06:00:00Z 1964-04-26T07:00:00Z 1964-10-25T06:00:00Z </code></pre> <p>There are other time zone IDs which map to "Eastern Standard Time", but I haven't found any which match the Windows behaviour.</p> <p>I don't think this is a <code>TimeZoneInfo</code> bug - I believe it's a potential problem in the underlying Windows time zone data.</p> <p>If you want to match TZDB data, of course, you can just use Noda Time :)</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload