I've also reproduced this behaviour on WinXP + MS SQL Server and would agree that it's a bug with the "fast=FALSE" option.
Have the package maintainers been contacted about this? >-----Original Message----- >From: [EMAIL PROTECTED] >[mailto:[EMAIL PROTECTED] On Behalf Of chao gai >Sent: 18 October 2006 08:10 PM >To: [email protected] >Subject: Re: [R] sqlSave, fast=F option, bug? > >The bug spot seems to be the fast option >sqlDrop(chan,'test') >df <- data.frame(T=1, S=10) >sqlSave(chan, df, "test", rownames=F) >df <- data.frame(S=20, T=2) >sqlSave(chan, df, "test", rownames=F, append=T,fast=T) df <- >data.frame(S=30, T=3) sqlSave(chan, df, "test", rownames=F, >append=T,fast=F) >sqlFetch(chan,'test') > T S >1 1 10 >2 2 20 >3 30 3 >On Linux & MySQL > > >On Wednesday 18 October 2006 17:06, Dieter Menne wrote: >> Paul MacManus <paul.macmanus <at> gmail.com> writes: >> > Using the fast=F option, sqlSave saves without matching >column names. >> > It looks like a bug to me.......... >> >> .... >> >> > In other words, sqlSave didn't check column names, it >simply mapped >> > column 1 to column 1 and column 2 to column 2. >> >> This seems to be a problem with SQLServer. The following >example with >> Access works correctly for me, even if I close the >connection in between. >> (Win2k, R 2.4.0) >> >> Dieter Menne >> >> ----- >> library(RODBC) >> channel <- odbcConnectAccess("db1.mdb") df <- data.frame(T=1, S=10) >> sqlSave(channel, df, "test", rownames=F) >> #odbcClose(channel) >> >> #channel <- odbcConnectAccess("db1.mdb") df <- data.frame(S=20, T=2) >> sqlSave(channel, df, "test", rownames=F, append=T,fast=T) >> odbcClose(channel) >> >> ______________________________________________ >> [email protected] 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. > >______________________________________________ >[email protected] 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. > ******************** Nedbank Limited Reg No 1951/000009/06. The following link displays the names of the Nedbank Board of Directors and Company Secretary. [ http://www.nedbank.co.za/terms/DirectorsNedbank.htm ] This email is confidential and is intended for the addressee only. The following link will take you to Nedbank's legal notice. [ http://www.nedbank.co.za/terms/EmailDisclaimer.htm ] ******************** [[alternative HTML version deleted]] ______________________________________________ [email protected] 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.
