File tree 1 file changed +24
-1
lines changed
1 file changed +24
-1
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ license: |
26
26
### Syntax
27
27
28
28
``` sql
29
- SHOW CREATE TABLE table_identifier
29
+ SHOW CREATE TABLE table_identifier [ AS SERDE ]
30
30
```
31
31
32
32
### Parameters
@@ -37,6 +37,10 @@ SHOW CREATE TABLE table_identifier
37
37
38
38
** Syntax:** ` [ database_name. ] table_name `
39
39
40
+ * ** AS SERDE**
41
+
42
+ Generates Hive DDL for a Hive SerDe table.
43
+
40
44
### Examples
41
45
42
46
``` sql
@@ -55,6 +59,25 @@ SHOW CREATE TABLE test;
55
59
' prop1' = ' value1' ,
56
60
' prop2' = ' value2' )
57
61
+ -- --------------------------------------------------+
62
+
63
+ SHOW CREATE TABLE test AS SERDE;
64
+ + -- ----------------------------------------------------------------------------+
65
+ | createtab_stmt|
66
+ + -- ----------------------------------------------------------------------------+
67
+ |CREATE TABLE ` default` .` test` (
68
+ ` c` INT )
69
+ ROW FORMAT SERDE ' org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe'
70
+ WITH SERDEPROPERTIES (
71
+ ' serialization.format' = ' ,' ,
72
+ ' field.delim' = ' ,' )
73
+ STORED AS
74
+ INPUTFORMAT ' org.apache.hadoop.mapred.TextInputFormat'
75
+ OUTPUTFORMAT ' org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat'
76
+ TBLPROPERTIES (
77
+ ' prop1' = ' value1' ,
78
+ ' prop2' = ' value2' ,
79
+ ' transient_lastDdlTime' = ' 1641800515' )
80
+ + -- ----------------------------------------------------------------------------+
58
81
```
59
82
60
83
### Related Statements
You can’t perform that action at this time.
0 commit comments