[R-sig-DB] [R] SQLite: When reading a table, a "\r" is padded onto the last column. Why?

Seth Falcon @|@|con @end|ng |rom |hcrc@org
Thu Jan 4 19:57:07 CET 2007


ronggui <ronggui.huang using gmail.com> writes:
> When write a data frame to db table, the problem of "\r" is fixed. But
> for importing data frome file, the problem is still there. When if the
> final line lacks the eol sign "\n", "\001x\001(" comes up.
>
>> dbWriteTable(con,"test","c:/test.txt",sep="\t",head=T,over=T,eol="\n")

You've specified eol="\n", but I'm pretty sure that is not the eol in
your file.  I suspect that if you try eol="\r\n", things will look as
you expect.

The bug that you found when there is no trailing eol is something I
will see about fixing.  But for now, the workaround is rather
clear. :-)

+ seth




More information about the R-sig-DB mailing list