DataFrameWriter.
insertInto
Inserts the content of the DataFrame to the specified table.
DataFrame
It requires that the schema of the DataFrame is the same as the schema of the table.
Optionally overwriting any existing data.
New in version 1.4.