2 years ago

#58894

test-img

anderwyang

In dplyr/sparklyr, when the variable names are Chinese, the `dplyr::copy_to` failed

In dplyr/sparklyr, when the variable names are Chinese, the dplyr::copy_to failed? Anyone can help? Thanks!

library(sparklyr)
library(tidyverse)
sc <- spark_connect(master='local')

#the variable name is Chinese, 'copy_to' failed
cat_sales_1 <- data.frame(品类=c('a','b','c'),金额=c(1,2,3))
cat_sales_df_1 <- copy_to(sc,cat_sales_1)

#the variable name is English, 'copy_to' succussed
cat_sales_2 <- data.frame(cat=c('a','b','c'),amount=c(1,2,3))
cat_sales_df_2 <- copy_to(sc,cat_sales_2)

r

dplyr

sparklyr

0 Answers

Your Answer

Accepted video resources