# Install PostgreSQL 8.4 - 32 bit and install pgJDBC Driver, OLEDB Driver from Stack Builder..........
# Install R 2.11.1 -32 bit
# Open R interface..
library(rJava)
library(DBI)
library(RJDBC)
library(RpgSQL)
.jinit(classpath=NULL,parameters=getOption("-Xmx4000m"),silent=FALSE,force.init=TRUE)
con <- dbConnect(pgSQL(), user = "username", password = "password", dbname = "db_name",host="hostname")
result<-dbGetQuery(con, 'select blah1, blah2 from "tbl_blh"')
str(result)
result
Cheers !!!
Wednesday, November 10, 2010
R Environment and PostgreSQL
Subscribe to:
Post Comments
(
Atom
)
0 comments :
Post a Comment