Marc Moragues a écrit : > Hello, > > I would like to retrieve data stored in MySQL database, so I installed > RMySQL package. > I can successfully connect with the my database using the following code > >> dvr<-dbDriver("MySQL") >> con2<-dbConnect(dvr,group="exbardiv") >> mysqlDescribeConnection(con2) > > <MySQLConnection:(972,0)> > User: mmorag > Host: localhost > Dbname: exbardiv > Connection type: localhost via TCP/IP > No resultSet available > > I can even see the tables in the database > >> dbListTables(con2) > [1] "agoueb" "high_ld" "rescue" "sjlc_info" "sjlc_ld" "temp" > > [7] "temp_snp1" "temp_snp2" > > However, when I try to query the database, R breakes.
What does *that* means ? You should be a bit more descriptive... > res<-dbSendQuery(con,'select * from sjlc_ld') require(MindeReaderAlpha). Hmmmm ... Isn't the "breakage" just a loooong wait with no answer ? Or maybe a timeout ? In which case I'd try to put a semicolon (";") at the end of the SQL query, thus making it syntactically valid SQL... HTH, Emmanuel Charpentier > Can anyone help me tune up the connection between R and MySQL? > > Thank you, > Marc. > _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ > > SCRI, Invergowrie, Dundee, DD2 5DA. > The Scottish Crop Research Institute is a charitable company limited by > guarantee. > Registered in Scotland No: SC 29367. > Recognised by the Inland Revenue as a Scottish Charity No: SC 006662. > > > DISCLAIMER: > > This email is from the Scottish Crop Research Institute, but the views > expressed by the sender are not necessarily the views of SCRI and its > subsidiaries. This email and any files transmitted with it are confidential > to the intended recipient at the e-mail address to which it has been > addressed. It may not be disclosed or used by any other than that addressee. > If you are not the intended recipient you are requested to preserve this > confidentiality and you must not use, disclose, copy, print or rely on this > e-mail in any way. Please notify [EMAIL PROTECTED] quoting the > name of the sender and delete the email from your system. > > Although SCRI has taken reasonable precautions to ensure no viruses are > present in this email, neither the Institute nor the sender accepts any > responsibility for any viruses, and it is your responsibility to scan the > email > and the attachments (if any). > > > ______________________________________________ > R-help@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.