powered by
Returns the specified Table as a SparkDataFrame. The Table must have already been registered in the SparkSession.
tableToDF(tableName)
The SparkSQL Table to convert to a SparkDataFrame.
SparkDataFrame
# NOT RUN { sparkR.session() path <- "path/to/file.json" df <- read.json(path) createOrReplaceTempView(df, "table") new_df <- tableToDF("table") # }
Run the code above in your browser using DataLab