I'm not sure if this problem is repeatable or particular to my machine. The following works fine -> odbcConnect("demoteam", uid = "demo", pwd = "demo")This causes R to crash -> oracle.info <- list(channel = "demoteam", uid = "demo", pwd = "demo") > demo.db.connect <- function(ora.info = oracle.info) {+ channel <- odbcConnect(ora.info$channel, uid = ora.info$uid, + pwd = ora.info$pwd) + if(channel == -1) stop("Connection Failure") + channel +}> #R shuts down as soon as I submit the next command > channel <- demo.db.connect()Thanks. Samir Mishra ==========================================Please send replies to : sqmishra at acm.org ========================================== _______________________________________________________ Send a cool gift with your E-Card http://www.bluemountain.com/giftcenter/ -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
> Date: Tue, 9 Jan 2001 04:43:19 -0800 (PST) > From: Samir Mishra <sqmishra at excite.com> > > I'm not sure if this problem is repeatable or particular to my machine. > > The following works fine - > > odbcConnect("demoteam", uid = "demo", pwd = "demo") > > This causes R to crash - > > oracle.info <- list(channel = "demoteam", uid = "demo", pwd = "demo") > > demo.db.connect <- function(ora.info = oracle.info) { > + channel <- odbcConnect(ora.info$channel, uid = ora.info$uid, > + pwd = ora.info$pwd) > + if(channel == -1) stop("Connection Failure") > + channel > +} > > #R shuts down as soon as I submit the next command > > channel <- demo.db.connect()It's very unlikely that we can debug this for you, especially as you haven't told us what version you are using of anything. In particular, the problem may well be in your ODBC client library and not in R. RODBC works well for me on both Windows and Linux, but I don't use Oracle. -- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272860 (secr) Oxford OX1 3TG, UK Fax: +44 1865 272595 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
My last message did not provide all the relevant information, sorry about the oversight. I'll start again... I'm not sure if this problem is repeatable or particular to my machine. The following works fine -> odbcConnect("demoteam", uid = "demo", pwd = "demo")This also works as expected -> demo.db.connect <- function(channel = "demoteam", uid = "demo",+ pwd = "demo") { + channel <- odbcConnect(channel = channel, uid = uid, pwd = pwd) + if(channel == -1) stop("Connection Failure") + channel +}> channel <- demo.db.connect()This causes R to crash -> oracle.info <- list(channel = "demoteam", uid = "demo", pwd = "demo") > demo.db.connect <- function(ora.info = oracle.info) {+ channel <- odbcConnect(ora.info$channel, uid = ora.info$uid, + pwd = ora.info$pwd) + if(channel == -1) stop("Connection Failure") + channel +}> #R shuts down as soon as I submit the next command > channel <- demo.db.connect()Version Info -> version_ platform i386-pc-mingw32 arch x86 os Win32 system x86, Win32 status major 1 minor 2.0 year 2000 month 12 day 15 language R Platform - WinNT ODBC Driver - Oracle ODBC Driver Ver. 8.01.05.00 (02/02/99) I've worked around the problem so this is not an issue, but I was curious to know if anyione else had experienced similar problems. Also, I was curious to know if there were any other issues I ought to be aware of, just so I can save some time later. Thanks. SM Samir Mishra ==========================================Please send replies to : sqmishra at acm.org ========================================== _______________________________________________________ Send a cool gift with your E-Card http://www.bluemountain.com/giftcenter/ -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
> Date: Tue, 9 Jan 2001 05:33:35 -0800 (PST) > From: Samir Mishra <sqmishra at excite.com>[...]> Platform - WinNT > ODBC Driver - Oracle ODBC Driver Ver. 8.01.05.00 (02/02/99) > > I've worked around the problem so this is not an issue, but I was curious to > know if anyione else had experienced similar problems. Also, I was curious > to know if there were any other issues I ought to be aware of, just so I can > save some time later.How about saving R-help's readers' time instead, even though you value it much below your own? -- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272860 (secr) Oxford OX1 3TG, UK Fax: +44 1865 272595 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._