Skip to content

Commit

Permalink
[SPARK-33208][SQL] Update the document of SparkSession#sql
Browse files Browse the repository at this point in the history
Change-Id: I82db1f9e8f667573aa3a03e05152cbed0ea7686b

### What changes were proposed in this pull request?
Update the document of SparkSession#sql, mention that this API eagerly runs DDL/DML commands, but not for SELECT queries.

### Why are the changes needed?
To clarify the behavior of SparkSession#sql.

### Does this PR introduce _any_ user-facing change?
No.

### How was this patch tested?
No needed.

Closes #30168 from waitinfuture/master.

Authored-by: zky.zhoukeyong <zky.zhoukeyong@alibaba-inc.com>
Signed-off-by: Wenchen Fan <wenchen@databricks.com>
  • Loading branch information
waitinfuture authored and cloud-fan committed Oct 28, 2020
1 parent 2b8fe6d commit b26ae98
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions sql/core/src/main/scala/org/apache/spark/sql/SQLContext.scala
Expand Up @@ -641,8 +641,8 @@ class SQLContext private[sql](val sparkSession: SparkSession)
}

/**
* Executes a SQL query using Spark, returning the result as a `DataFrame`. The dialect that is
* used for SQL parsing can be configured with 'spark.sql.dialect'.
* Executes a SQL query using Spark, returning the result as a `DataFrame`.
* This API eagerly runs DDL/DML commands, but not for SELECT queries.
*
* @group basic
* @since 1.3.0
Expand Down
Expand Up @@ -600,7 +600,7 @@ class SparkSession private(

/**
* Executes a SQL query using Spark, returning the result as a `DataFrame`.
* The dialect that is used for SQL parsing can be configured with 'spark.sql.dialect'.
* This API eagerly runs DDL/DML commands, but not for SELECT queries.
*
* @since 2.0.0
*/
Expand Down

0 comments on commit b26ae98

Please sign in to comment.