-
Notifications
You must be signed in to change notification settings - Fork 28.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[SPARK-28813][DOC][SQL] Document SHOW CREATE TABLE in SQL Reference #25885
Conversation
@dilipbiswal @gatorsmile |
Test build #111126 has finished for PR 25885 at commit
|
@@ -19,4 +19,39 @@ license: | | |||
limitations under the License. | |||
--- | |||
|
|||
**This page is under construction** | |||
### Description | |||
`SHOW CREATE TABLE` returns the `CREATE TABLE` statement that creates a given table. `SHOW CREATE TABLE` on a non-existent table throws Exception. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@huaxingao Should we show the "CREATE TABLE" as a link here ? Also how about :
SHOW CREATE TABLE
returns the [CREATE TABLE LINK] that was used create a given table ?
@@ -19,4 +19,39 @@ license: | | |||
limitations under the License. | |||
--- | |||
|
|||
**This page is under construction** | |||
### Description | |||
`SHOW CREATE TABLE` returns the `CREATE TABLE` statement that creates a given table. `SHOW CREATE TABLE` on a non-existent table throws Exception. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@huaxingao Does this work on a view ? If so, can we spell it out as such ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this works on a view. I will add it.
|
||
### Examples | ||
{% highlight sql %} | ||
CREATE TABLE test (c INT); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@huaxingao Actually i don't feel strongly about it. So you can safely ignore this comment. I was thinking if we should have this DDL with explicit, row format serde, storage properties .. so that there is less gap between input and output. What do you think ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will change my example.
Test build #111173 has finished for PR 25885 at commit
|
Hi, @huaxingao . Thank you for making PRs always. Since you are not a new commer, I'd like to recommend you to use a proper PR title |
Sorry, I will be more careful next time. @dongjoon-hyun |
Test build #111305 has finished for PR 25885 at commit
|
LGTM |
@@ -19,4 +19,46 @@ license: | | |||
limitations under the License. | |||
--- | |||
|
|||
**This page is under construction** | |||
### Description | |||
`SHOW CREATE TABLE` returns the [CREATE TABLE statement](sql-ref-syntax-ddl-create-table.html) or [CREATE VIEW statement](sql-ref-syntax-ddl-create-view.html) that was used to create a given table or view. `SHOW CREATE TABLE` on a non-existent table or a temporary view throws Exception. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
throws Exception -> throws an exception
Test build #111785 has finished for PR 25885 at commit
|
Merged to master |
Thanks! @srowen @dilipbiswal |
What changes were proposed in this pull request?
Document SHOW CREATE TABLE statement in SQL Reference
Why are the changes needed?
To complete the SQL reference.
Does this PR introduce any user-facing change?
Yes.
after the change:
How was this patch tested?
Tested using jykyll build --serve