insertInto,DataFrame,character-method {SparkR} | R Documentation |
Insert the contents of a DataFrame into a table registered in the current SQL Context.
## S4 method for signature 'DataFrame,character' insertInto(x, tableName, overwrite = FALSE) insertInto(x, tableName, ...)
x |
A SparkSQL DataFrame |
tableName |
A character vector containing the name of the table |
overwrite |
A logical argument indicating whether or not to overwrite the existing rows in the table. |
## Not run:
##D sc <- sparkR.init()
##D sqlContext <- sparkRSQL.init(sc)
##D df <- read.df(sqlContext, path, "parquet")
##D df2 <- read.df(sqlContext, path2, "parquet")
##D registerTempTable(df, "table1")
##D insertInto(df2, "table1", overwrite = TRUE)
## End(Not run)