Hi, I am trying to read data from Microsoft SQL. I tried to use odbcConnect (in RODBC) but failed. What should the "dsn" be? Does anyone know how to do it? I will appreciate it. Thank you! Xiaorong ________________________________________________________________________ The preceding e-mail message (including any attachments) contains information that may be confidential, be protected by the attorney-client or other applicable privileges, or constitute non-public information. It is intended to be read only by the individual or entity to whom it is addressed or by their designee. If you are not an intended recipient of this message, please notify the sender by replying to this message and then delete it from your system. You are on notice that further use, dissemination, distribution, or reproduction of this message is strictly prohibited and may be unlawful. [[alternative HTML version deleted]]
Xiaorong Chen wrote:> Hi, > > I am trying to read data from Microsoft SQL. I tried to use odbcConnect > (in RODBC) but failed. What should the "dsn" be? Does anyone know how to > do it? I will appreciate it.The dsn is that one you have entered in the control panel before. (there you have to specify data source name and corresponding host, user name, and name of the database). Uwe Ligges> Thank you! > > Xiaorong > ________________________________________________________________________ > The preceding e-mail message (including any attachments) contains > information that may be confidential, be protected by the > attorney-client or other applicable privileges, or constitute non-public > information. It is intended to be read only by the individual or entity > to whom it is addressed or by their designee. If you are not an intended > recipient of this message, please notify the sender by replying to this > message and then delete it from your system. You are on notice that > further use, dissemination, distribution, or reproduction of this > message is strictly prohibited and may be unlawful. > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at stat.math.ethz.ch mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Hi, the DSN should be exactly the same as "name" of the (probably system) DSN stated in Windows ODBC settings. Just keep in mind, that DSN in general often holds information about the Default Database, and that switching database os stating database as prefix may be necessary. Jan - - - Original message: - - - From: r-help-bounces at stat.math.ethz.ch Send: 1.11.2004 19:10:47 To: <R-help at stat.math.ethz.ch> Subject: [R] Read in data from Microsoft SQL Hi, I am trying to read data from Microsoft SQL. I tried to use odbcConnect (in RODBC) but failed. What should the "dsn" be? Does anyone know how to do it? I will appreciate it. Thank you! Xiaorong ________________________________________________________________________ The preceding e-mail message (including any attachments) contains information that may be confidential, be protected by the attorney-client or other applicable privileges, or constitute non-public information. It is intended to be read only by the individual or entity to whom it is addressed or by their designee. If you are not an intended recipient of this message, please notify the sender by replying to this message and then delete it from your system. You are on notice that further use, dissemination, distribution, or reproduction of this message is strictly prohibited and may be unlawful. [[alternative HTML version deleted]] ______________________________________________ R-help at stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
On Tue, 2 Nov 2004 Jan_Svatos at eurotel.cz wrote:> Hi, > > the DSN should be exactly the same as "name" of the (probably system) DSN > stated in Windows ODBC settings. > Just keep in mind, that DSN in general often holds information about the > Default Database, and that switching database os stating database as > prefix may be necessary.Yes, assuming this _is_ on Windows (unstated). In that case and under RGui, just use odbcDriverConnect() and you will get dialog boxes to select a dsn, or setup a temporary one (via the New button).> > Jan > > > - - - Original message: - - - > From: r-help-bounces at stat.math.ethz.ch > Send: 1.11.2004 19:10:47 > To: <R-help at stat.math.ethz.ch> > Subject: [R] Read in data from Microsoft SQL > > Hi, > > I am trying to read data from Microsoft SQL. I tried to use odbcConnect > (in RODBC) but failed. What should the "dsn" be? Does anyone know how to > do it? I will appreciate it. > > Thank you! > > Xiaorong-- 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 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595