Re: [R] Strange RODBC problem

2007-06-27 Thread David Einstein
On 6/26/07, Richard M. Heiberger <[EMAIL PROTECTED]> wrote:
>
> > I am using RODBC to collect data from an ODBC connection to an MS Access
> > Database.  Everything seems to be working well except datetimes between
> > March 12, 2006 02:00 and 02:59 get moved one hour forward.  This does
> not
> > seem to be happening with Excel connecting to the same
> connection.  March 12
> > seems a bit early for Daylight savings time.  What am I doing wrong?
>
> In 2007, the US moved daylight savings to March 11 instead of the more
> traditional
> first weekend in April.  It continues to November 4, a week later than
> before.
> Google "daylight savings 2007" for lots of background.
>
> Some MS programs did not make the switch until April 1, therefore my
> calendars
> doubled up continuing appointments.
>
> From your experience, it looks like some programs are retroactively
> misapplying
> the change to 2006.



This appears to be a strange interaction between R and Windows.  If I have
windows set to "automatically adjust clock for Daylight Savings changes"
then in R I get the following

> as.POSIXct("2006-03-12 01:05:00 EST5EDT",tz="EST")
[1] "2006-03-12 01:05:00 EST"
> as.POSIXct("2006-03-12 03:05:00 EST5EDT",tz="EST")
[1] "2006-03-12 02:05:00 EST"

If I uncheck the "automatically adjust clock for Daylight Savings" checkbox
I get

> as.POSIXct("2006-03-12 01:05:00 EST5EDT",tz="EST")
[1] "2006-03-12 01:05:00 EST"
> as.POSIXct("2006-03-12 03:05:00 EST5EDT",tz="EST")
[1] "2006-03-12 03:05:00 EST"

All of which makes my head hurt.  At least now I can read the query with
as.is=TRUE  and set the tz explicitly.

[[alternative HTML version deleted]]

__
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] Strange RODBC problem

2007-06-27 Thread David Einstein
On 6/26/07, Richard M. Heiberger <[EMAIL PROTECTED]> wrote:
> > I am using RODBC to collect data from an ODBC connection to an MS Access
> > Database.  Everything seems to be working well except datetimes between
> > March 12, 2006 02:00 and 02:59 get moved one hour forward.  This does not
> > seem to be happening with Excel connecting to the same connection.  March 12
> > seems a bit early for Daylight savings time.  What am I doing wrong?
>
> In 2007, the US moved daylight savings to March 11 instead of the more 
> traditional
> first weekend in April.  It continues to November 4, a week later than before.
> Google "daylight savings 2007" for lots of background.
>
> Some MS programs did not make the switch until April 1, therefore my calendars
> doubled up continuing appointments.
>
> From your experience, it looks like some programs are retroactively 
> misapplying
> the change to 2006.
>
Thanks, that seems to be the problem. Now I need to figure out how to
fix it, but I know where to look.

__
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] Strange RODBC problem

2007-06-26 Thread Richard M. Heiberger
> I am using RODBC to collect data from an ODBC connection to an MS Access
> Database.  Everything seems to be working well except datetimes between
> March 12, 2006 02:00 and 02:59 get moved one hour forward.  This does not
> seem to be happening with Excel connecting to the same connection.  March 12
> seems a bit early for Daylight savings time.  What am I doing wrong?

In 2007, the US moved daylight savings to March 11 instead of the more 
traditional
first weekend in April.  It continues to November 4, a week later than before.
Google "daylight savings 2007" for lots of background.

Some MS programs did not make the switch until April 1, therefore my calendars
doubled up continuing appointments.

>From your experience, it looks like some programs are retroactively misapplying
the change to 2006.

__
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] Strange RODBC problem

2007-06-26 Thread David Einstein
I am using RODBC to collect data from an ODBC connection to an MS Access
Database.  Everything seems to be working well except datetimes between
March 12, 2006 02:00 and 02:59 get moved one hour forward.  This does not
seem to be happening with Excel connecting to the same connection.  March 12
seems a bit early for Daylight savings time.  What am I doing wrong?

R 2.5.0  Windows XP with the latest RODBC (I'm not sure how to get the
versions of the packages in use)

Thank you very much,
   deinst

(R is a fantastic package.)

[[alternative HTML version deleted]]

__
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.