Reputation: 589
n = c(2, 3, 5)
s = c("aa", "bb", "cc")
b = c(TRUE, FALSE, TRUE)
df = data.frame(n, s, b)
ch <- odbcConnect("Drill")
sqlSave(ch, df, tablename = "tblTest", rownames=FALSE, append=TRUE)
When I executed the code above, it throws exception:
Error in sqlSave(ch, df, tablename = "tblTest", rownames = FALSE, append = FALSE) :
HY000 1040 [MapR][Drill] (1040) Drill failed to execute the query: CREATE TABLE "tblTest" ("n" DOUBLE, "s" varchar(255), "b" varchar(255))
[30024]Query execution error. Details:[
ParseException: Encountered "\"" at line 1, column 14.
Was expecting one of:
<IDENTIFIER> ...
<QUOTED_IDENTIFIER> ...
<BACK_QUOTED_IDENTIFIER> ...
<BRACKET_QUOTED_IDENTIFIER> ...
<UNICODE_QUOTED_IDENTIFIER> ...
]
I researched quite long on the internet, but still can't find a solution. Is there anyone can help? Thanks.
Upvotes: 1
Views: 431
Reputation: 8044
Maybe you should have a look at rhdfs
package?
https://github.com/RevolutionAnalytics/rhdfs
Upvotes: 1