[R] Extracting data from SQL Server based on R parameters
dthomas
dyfed.thomas at midlandshn.health.nz
Mon Jan 23 06:07:53 CET 2012
Hi,
Can you extract data from a SQL server table based on parameters already in
R? For example I have a list of unique patient IDs with latest
hospitalisation date which I've processed in R. I need to join this data to
other tables in SQL server. The tables in SQL server are too large to import
without reducing the number of records. I do not have write access to the
SQL server.
mMPILatestHosp #this is my data frame of patients with unique IDs (ID) and
most recent date (EVENDate)
The select query is easy
query<-"select * (plus columns in mMPILatestHosp) from Pharm2011
where....#This is where I want to insert mMPILatestHosp$ID in the where
clause"
I'm new to R so would appreciate your help.
Cheers
D
--
View this message in context: http://r.789695.n4.nabble.com/Extracting-data-from-SQL-Server-based-on-R-parameters-tp4319919p4319919.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list