run(sparkSession: SparkSession): Seq[Row]
CreateDataSourceTableCommand Logical Command
CreateDataSourceTableCommand
is a logical command that creates a new table (in a SessionCatalog).
CreateDataSourceTableCommand
is created when DataSourceAnalysis posthoc logical resolution rule resolves a CreateTable logical operator for a non-Hive table provider with no query.
Creating CreateDataSourceTableCommand Instance
CreateDataSourceTableCommand
takes the following to be created:
CreateDataSourceTableCommand
initializes the internal properties.
Executing Logical Command — run
Method
Note
|
run is part of RunnableCommand Contract to execute (run) a logical command.
|
run
creates a new table in a session-scoped SessionCatalog
.
Note
|
run uses the input SparkSession to access SessionState that in turn is used to access the current SessionCatalog.
|
Internally, run
creates a BaseRelation to access the table’s schema.
Caution
|
FIXME |
Note
|
run accepts tables only (not views) with the provider defined.
|