I had a similar problem when I posted this recently:

RODBC and Excel: Wrong Data Type Assumed on Import
http://tolstoy.newcastle.edu.au/~rking/R/help/05/11/14938.html

My conclusion was: "Being lucky" shouldn't be part of processing Excel
files, which is the case when RODBC is used.

This reply gave some suggestions:
http://tolstoy.newcastle.edu.au/~rking/R/help/05/11/14990.html

I found this suggestion the most useful:

"You could try using the COM interface rather than the ODBC interface"
http://tolstoy.newcastle.edu.au/~rking/R/help/05/11/15030.html

This approach has problems if you have "holes" in your data, but with some
work I found RDCOMClient the way to go:
http://tolstoy.newcastle.edu.au/~rking/R/help/05/11/15090.html

IMHO, RODBC should only be used if you have an Excel file without holes, and
with very regular numeric data.  I don't understand why the online
documentation is not updated to give a usage note that RODBC will often fail
reading Excel files.

Specifically,

this help:

  library(RODBC)
  ?odbcConnectExce

should be modified to have a warning "RODBC considered harmful with Excel
files"

efg


"Keith Sabol" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> I am using the RODBC package to read data from an Excel file.
> ...
> My problem appears to be related to specification of data types by column.

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

Reply via email to