1

I can not append data frame into the an existing table, because the table in access has white space. e.g.

  • Access table variable name: Dlr Name
  • data frame variable name: DlrName

I try to replicate access table variable name to my df using varTypes=varTypes, but when I run the following code

sqlSave(access, Contracts_CurrMth, "T_Contracts", append=TRUE, rownames=FALSE, fast=FALSE, safer=TRUE, verbose=TRUE)

Looks like R automatically delete the space in my df variable name and The error msg is

HYS22 -1507 [Microsoft][ODBC Microsoft Access Driver] The INSERT INTO statement contains the following unknown field name: DlrName


Anyone can help me on this please?

Some more background info:

R 32bit, access 2010, 32bit, both data table are same format my data frame table is like this data frame

my access table is like this access table

C_Mu
  • 305
  • 4
  • 14
  • This looks like a duplicate of https://stackoverflow.com/questions/37240553/unable-to-append-to-sql-server-table-using-sqlsave-in-r. The (unaccepted) answer there points the finger at column names and data types. – Peter Dec 12 '17 at 19:31
  • just edit my post, looks like it is related to the name space. I believe they are not the same problem. But thank you very much for your help! – C_Mu Dec 12 '17 at 19:46

0 Answers0