Learn R Programming

SparkR (version 3.1.2)

registerTempTable: (Deprecated) Register Temporary Table

Description

Registers a SparkDataFrame as a Temporary Table in the SparkSession

Usage

registerTempTable(x, tableName)

# S4 method for SparkDataFrame,character registerTempTable(x, tableName)

Arguments

x

A SparkDataFrame

tableName

A character vector containing the name of the table

See Also

createOrReplaceTempView

Examples

Run this code
# NOT RUN {
sparkR.session()
path <- "path/to/file.json"
df <- read.json(path)
registerTempTable(df, "json_df")
new_df <- sql("SELECT * FROM json_df")
# }

Run the code above in your browser using DataLab