This is an automated email from the ASF dual-hosted git repository. gengliang 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 2f70e4f [SPARK-37818][DOCS] Add option in the description document for show create table 2f70e4f is described below commit 2f70e4f84073ac75457263a2b3f3cb835ee63d49 Author: PengLei <peng.8...@gmail.com> AuthorDate: Mon Jan 10 19:40:02 2022 +0800 [SPARK-37818][DOCS] Add option in the description document for show create table ### What changes were proposed in this pull request? Add options in the description document for `SHOW CREATE TABLE ` command. <img width="767" alt="1" src="https://user-images.githubusercontent.com/41178002/148747443-ecd6586f-e4c4-4ae4-8ea5-969896b7d416.png"> <img width="758" alt="2" src="https://user-images.githubusercontent.com/41178002/148747457-873bc0c3-08fa-4d31-89e7-b44440372462.png"> ### Why are the changes needed? [#discussion](https://github.com/apache/spark/pull/34719#discussion_r758189709) ### Does this PR introduce _any_ user-facing change? No ### How was this patch tested? SKIP_API=1 SKIP_RDOC=1 SKIP_PYTHONDOC=1 SKIP_SCALADOC=1 bundle exec jekyll build Closes #35107 from Peng-Lei/SPARK-37818. Authored-by: PengLei <peng.8...@gmail.com> Signed-off-by: Gengliang Wang <gengli...@apache.org> --- docs/sql-ref-syntax-aux-show-create-table.md | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/docs/sql-ref-syntax-aux-show-create-table.md b/docs/sql-ref-syntax-aux-show-create-table.md index ae8c10e..83013b0 100644 --- a/docs/sql-ref-syntax-aux-show-create-table.md +++ b/docs/sql-ref-syntax-aux-show-create-table.md @@ -26,7 +26,7 @@ license: | ### Syntax ```sql -SHOW CREATE TABLE table_identifier +SHOW CREATE TABLE table_identifier [ AS SERDE ] ``` ### Parameters @@ -37,6 +37,10 @@ SHOW CREATE TABLE table_identifier **Syntax:** `[ database_name. ] table_name` +* **AS SERDE** + + Generates Hive DDL for a Hive SerDe table. + ### Examples ```sql @@ -55,6 +59,25 @@ SHOW CREATE TABLE test; 'prop1' = 'value1', 'prop2' = 'value2') +----------------------------------------------------+ + +SHOW CREATE TABLE test AS SERDE; ++------------------------------------------------------------------------------+ +| createtab_stmt| ++------------------------------------------------------------------------------+ +|CREATE TABLE `default`.`test`( + `c` INT) + ROW FORMAT SERDE 'org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe' + WITH SERDEPROPERTIES ( + 'serialization.format' = ',', + 'field.delim' = ',') + STORED AS + INPUTFORMAT 'org.apache.hadoop.mapred.TextInputFormat' + OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat' + TBLPROPERTIES ( + 'prop1' = 'value1', + 'prop2' = 'value2', + 'transient_lastDdlTime' = '1641800515') ++------------------------------------------------------------------------------+ ``` ### Related Statements --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@spark.apache.org For additional commands, e-mail: commits-h...@spark.apache.org