You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spark.apache.org by do...@apache.org on 2020/12/23 23:39:18 UTC

[spark] branch branch-3.1 updated: [SPARK-33877][SQL][FOLLOWUP] SQL reference documents for INSERT w/ a column list

This is an automated email from the ASF dual-hosted git repository.

dongjoon pushed a commit to branch branch-3.1
in repository https://gitbox.apache.org/repos/asf/spark.git


The following commit(s) were added to refs/heads/branch-3.1 by this push:
     new 10cb18f  [SPARK-33877][SQL][FOLLOWUP] SQL reference documents for INSERT w/ a column list
10cb18f is described below

commit 10cb18f39b73ac67d91613ec57084bfcb466cb4f
Author: Kent Yao <ya...@hotmail.com>
AuthorDate: Wed Dec 23 15:38:32 2020 -0800

    [SPARK-33877][SQL][FOLLOWUP] SQL reference documents for INSERT w/ a column list
    
    ### What changes were proposed in this pull request?
    
    followup of https://github.com/apache/spark/commit/a3dd8dacee8f6b316be90500f9fd8ec8997a5784 via suggestion https://github.com/apache/spark/pull/30888#discussion_r547822642
    ### Why are the changes needed?
    
    doc improvement
    ### Does this PR introduce _any_ user-facing change?
    
    no
    
    ### How was this patch tested?
    
    passing GA doc
    
    Closes #30909 from yaooqinn/SPARK-33877-F.
    
    Authored-by: Kent Yao <ya...@hotmail.com>
    Signed-off-by: Dongjoon Hyun <dh...@apple.com>
    (cherry picked from commit 368a2c341d8f3315c759e1c2362439534a9d44e7)
    Signed-off-by: Dongjoon Hyun <dh...@apple.com>
---
 docs/sql-ref-syntax-dml-insert-into.md            | 3 +--
 docs/sql-ref-syntax-dml-insert-overwrite-table.md | 3 +--
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/docs/sql-ref-syntax-dml-insert-into.md b/docs/sql-ref-syntax-dml-insert-into.md
index 96a95b1..1540078 100644
--- a/docs/sql-ref-syntax-dml-insert-into.md
+++ b/docs/sql-ref-syntax-dml-insert-into.md
@@ -47,12 +47,11 @@ INSERT INTO [ TABLE ] table_identifier [ partition_spec ] [ ( column_list ) ]
 
 * **column_list**
 
-    An optional parameter that specifies a comma-separated list of columns belonging to the `table_identifier` table.
+    An optional parameter that specifies a comma-separated list of columns belonging to the `table_identifier` table. Spark will reorder the columns of the input query to match the table schema according to the specified column list.
 
     **Note:**The current behaviour has some limitations:
     - All specified columns should exist in the table and not be duplicated from each other. It includes all columns except the static partition columns.
     - The size of the column list should be exactly the size of the data from `VALUES` clause or query.
-    - The order of the column list is alterable and determines how the data from `VALUES` clause or query to be inserted by position.
 
 * **VALUES ( { value `|` NULL } [ , ... ] ) [ , ( ... ) ]**
 
diff --git a/docs/sql-ref-syntax-dml-insert-overwrite-table.md b/docs/sql-ref-syntax-dml-insert-overwrite-table.md
index f2413fb..5fd0880 100644
--- a/docs/sql-ref-syntax-dml-insert-overwrite-table.md
+++ b/docs/sql-ref-syntax-dml-insert-overwrite-table.md
@@ -47,14 +47,13 @@ INSERT OVERWRITE [ TABLE ] table_identifier [ partition_spec [ IF NOT EXISTS ] ]
 
 * **column_list**
 
-    An optional parameter that specifies a comma-separated list of columns belonging to the `table_identifier` table.
+    An optional parameter that specifies a comma-separated list of columns belonging to the `table_identifier` table. Spark will reorder the columns of the input query to match the table schema according to the specified column list.
 
     **Note**
 
     The current behaviour has some limitations:
     - All specified columns should exist in the table and not be duplicated from each other. It includes all columns except the static partition columns.
     - The size of the column list should be exactly the size of the data from `VALUES` clause or query.
-    - The order of the column list is alterable and determines how the data from `VALUES` clause or query to be inserted by position.
 
 * **VALUES ( { value `|` NULL } [ , ... ] ) [ , ( ... ) ]**
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@spark.apache.org
For additional commands, e-mail: commits-help@spark.apache.org