You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spark.apache.org by ya...@apache.org on 2023/06/16 03:08:01 UTC

[spark] branch master updated: [SPARK-44072][DOCS] Update insert table docs for incorrect sql example

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

yao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/spark.git


The following commit(s) were added to refs/heads/master by this push:
     new 34f2c39bf75 [SPARK-44072][DOCS] Update insert table docs for incorrect sql example
34f2c39bf75 is described below

commit 34f2c39bf7538508a7d0d18bf68ce14da66de5fe
Author: yangchuan <ya...@alibaba-inc.com>
AuthorDate: Fri Jun 16 11:07:42 2023 +0800

    [SPARK-44072][DOCS] Update insert table docs for incorrect sql example
    
    ### What changes were proposed in this pull request?
    
    Latest docs of insert table about [Insert Using a Typed Date Literal for a Partition Column Value](https://spark.apache.org/docs/latest/sql-ref-syntax-dml-insert-table.html#insert-using-a-typed-date-literal-for-a-partition-column-value-1) has an incorrect sql example, it does not match the context and sql results.
    
    Correct sql example for that should be
    ```
    INSERT OVERWRITE students PARTITION (birthday = date'2019-01-02') VALUES('Jason Wang', '908 Bird St, Saratoga');
    ```
    ### Why are the changes needed?
    
    Use a correct sql example for `Insert Using a Typed Date Literal for a Partition Column Value`.
    
    ### Does this PR introduce _any_ user-facing change?
    
    No
    
    ### How was this patch tested?
    
    Manual test
    
    Closes #41619 from Yohahaha/SPARK44072.
    
    Authored-by: yangchuan <ya...@alibaba-inc.com>
    Signed-off-by: Kent Yao <ya...@apache.org>
---
 docs/sql-ref-syntax-dml-insert-table.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/docs/sql-ref-syntax-dml-insert-table.md b/docs/sql-ref-syntax-dml-insert-table.md
index 1d2fe4d969a..ea8a2789cae 100644
--- a/docs/sql-ref-syntax-dml-insert-table.md
+++ b/docs/sql-ref-syntax-dml-insert-table.md
@@ -419,7 +419,7 @@ SELECT * FROM students;
 |    Amy Smith|   123 Park Ave, San Jose| 2019-01-02|
 +-------------+-------------------------+-----------+
 
-INSERT INTO students PARTITION (birthday = date'2019-01-02')
+INSERT OVERWRITE students PARTITION (birthday = date'2019-01-02')
     VALUES('Jason Wang', '908 Bird St, Saratoga');
 
 SELECT * FROM students;


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