From: Scillieri, John <>
Date: Tue, 5 Feb 2008 17:11:09 -0500

That did it, thanks.

-----Original Message-----
From: Prof Brian Ripley [] Sent: Tuesday, February 05, 2008 4:28 PM To: Scillieri, John
Subject: Re: [R] SAS ODBC

See the help page for odbcConnect. I have no experience with that ODBC driver, but a few contain errors and need believeNRows = FALSE.

On Tue, 5 Feb 2008, Scillieri, John wrote:

> All,
> I'm trying to connect to a remote SAS server using SAS's 9.1 ODBC
> driver and the RODBC package. I'm running R-2.6.1 on Win XP. I can
> successfully connect to the database, but no matter which table I
> query, I get back an empty table with only the column headers. For
> > sqlQuery(con, "select * from PRICES.DB_PRICES")
> <0 rows> (or 0-length row.names)
> sqlTables also returns back an empty table:
> > sqlTables(con)
> <0 rows> (or 0-length row.names)
> And sqlFetch doesn't work either:
> > sqlFetch(con, "PRICES.DB_PRICES")
> Error in odbcTableExists(channel, sqtable) :
> 'PRICES.DB_PRICES': table not found on channel

That won't work: SQL tables cannot have periods in their names.

> Are their other options I should be using with RODBC to pull the data?

> I have tested the connection in MS Access and can successfully display

> data (using File->Get External Data...->ODBC->...)
> Any suggestions would be great, thanks in advance for your help.
> John Scillieri
>>>> This e-mail and any attachments are confidential, may contain

>>>> legal,
> professional or other privileged information, and are intended solely
> for the addressee. If you are not the intended recipient, do not use
> the information in this e-mail in any way, delete this e-mail and
> notify the sender. CEG-IP2
> ______________________________________________
> mailing list
> PLEASE do read the posting guide
> and provide commented, minimal, self-contained, reproducible code.

Brian D. Ripley,        
Professor of Applied Statistics,
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595

______________________________________________ mailing list
PLEASE do read the posting guide
and provide commented, minimal, self-contained, reproducible code.
Received on Tue 05 Feb 2008 - 22:16:00 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Tue 05 Feb 2008 - 22:30:11 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.

list of date sections of archive