YUECHEN0830 / DSP_Data_Geek_Solar_Energy

0 stars 2 forks source link

Error Code 1045 #8

Open Marco-Sulser opened 4 years ago

Marco-Sulser commented 4 years ago

MySQL can produce the Error Code 1045, when the function LOAD DATA INFILE is used. According to forums and literature user specific privileges would need to be flushed. This is especially necessary when MySQL workbench is used.

And easy workaround for this is to use the RMySQL package out of RStudio.

frame <- read_csv('path/filename.csv') dbWriteTable(, , , append=TRUE, row.names=FALSE)

We further recognised that the read_csv function from the tidyverse package has shown itself as more reliable and stable than any import wizard or IDA such as MySQL workbench.

rato-li commented 4 years ago

Agreed, Marco. Normally I'd prefer to use SQL to do stuff inside the database. But when it is about file input or output, SQL does not make is easy compared to the tools or wizards provided by the SQL editor (like MySQLworkbench.)