s-news
[Top] [All Lists]

ODBC question

To: s-news@lists.biostat.wustl.edu
Subject: ODBC question
From: Ita.Cirovic-Donev@hypo-alpe-adria.com
Date: Tue, 16 May 2006 16:31:52 +0200
Importance: Normal
Keywords:
Sensitivity:



Hi all,

simple ODBC question. I have been using ODBC to connect to MSAccess
database in R. Now I purchased S-Plus 7 and need to do the same thing. Can
someone help out in what I am doing wrong. Thanks.

System DSN: mydata
database: mydatabase
table: my table

I run the following code:

finaldata <- importData(type="ODBC", user="me",
password="22222",database="mydatabase",
                  table="mytable", stringsAsFactors=F, bigdata=T)


channel <- "DSN=mydata;UID=me;PWD=22222;DATABASE=mydatabase"

openDBConnection();

executeSQL(type="ODBC", user="me", password="22222", database="mydatabase",
           odbcConnection=channel, sqlQuery="create table TRYTABLE as
select * from mytable")

closeDBConnection()


First I do get finaldata correctly as big data frame. The table mytable has
1.5 million rows and 154 columns. The problem is when I want to open the
connection to do SQL commands. The error is

NULL data frame with 0 rows


thanks.

Ita


<Prev in Thread] Current Thread [Next in Thread>