From bad358af7a6c5c09da233cd58ada88308ca10921 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A8=8B=E4=BA=A6=E8=B6=85=28=E4=BD=95=E5=85=AE=29?= Date: Thu, 12 May 2016 13:28:55 +0800 Subject: [PATCH 1/4] odps-ddl: add page Change-Id: I75366bdb9f6c96136c4838c6961159418a77dae7 --- pages/common/odps-sql.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 pages/common/odps-sql.md diff --git a/pages/common/odps-sql.md b/pages/common/odps-sql.md new file mode 100644 index 0000000000..0e570e4fb0 --- /dev/null +++ b/pages/common/odps-sql.md @@ -0,0 +1,23 @@ +# odps ddl + +> Run ddl task in odps. + +- Create a table with partition and lifecycle: + +`create table {{table_name}} ({{col}} {{type}}) partitioned by ({{col}} {{type}}) lifecycle {{days}};` + +- Create a table based on the definition of another table: + +`create table {{table_name}} like {{another_table}};` + +- Add parition to a table: + +`alter table {{table_name}} add parition ({{partition_spec}});` + +- Delete partition from a table: + +`alter table {{table_name}} drop partition ({{partition_spec}});` + +- Delete table: + +`drop table {{table_name}};` From b0e464f98cf436da8339ad3829a92027ba6d77fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A8=8B=E4=BA=A6=E8=B6=85=28=E4=BD=95=E5=85=AE=29?= Date: Thu, 12 May 2016 13:31:28 +0800 Subject: [PATCH 2/4] odps-ddl: rename file Change-Id: I07dca5d9f840490130111da257c38b4d93f4da6d --- pages/common/{odps-sql.md => odps-ddl.md} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename pages/common/{odps-sql.md => odps-ddl.md} (100%) diff --git a/pages/common/odps-sql.md b/pages/common/odps-ddl.md similarity index 100% rename from pages/common/odps-sql.md rename to pages/common/odps-ddl.md From bbc52a9fc70e5c6bf6eae86ce158d891f49d6659 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A8=8B=E4=BA=A6=E8=B6=85=28=E4=BD=95=E5=85=AE=29?= Date: Thu, 12 May 2016 18:16:03 +0800 Subject: [PATCH 3/4] odps-ddl: typo Change-Id: I5ec6a100ae27992deb571a56481f65a07b18c14e --- pages/common/odps-ddl.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/common/odps-ddl.md b/pages/common/odps-ddl.md index 0e570e4fb0..ea09653532 100644 --- a/pages/common/odps-ddl.md +++ b/pages/common/odps-ddl.md @@ -1,6 +1,6 @@ # odps ddl -> Run ddl task in odps. +> Run ddl task in ODPS (Open Data Processing Service). - Create a table with partition and lifecycle: @@ -10,7 +10,7 @@ `create table {{table_name}} like {{another_table}};` -- Add parition to a table: +- Add partition to a table: `alter table {{table_name}} add parition ({{partition_spec}});` From dc961a64001e21abff6a213fa9fb245774f1ad34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A8=8B=E4=BA=A6=E8=B6=85=28=E4=BD=95=E5=85=AE=29?= Date: Thu, 12 May 2016 20:35:27 +0800 Subject: [PATCH 4/4] odps-table: rename ddl to table Change-Id: I85f19f6fdb1df566a500a4353345b2e4b10b2f48 --- pages/common/{odps-ddl.md => odps-table.md} | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) rename pages/common/{odps-ddl.md => odps-table.md} (86%) diff --git a/pages/common/odps-ddl.md b/pages/common/odps-table.md similarity index 86% rename from pages/common/odps-ddl.md rename to pages/common/odps-table.md index ea09653532..aae8049a03 100644 --- a/pages/common/odps-ddl.md +++ b/pages/common/odps-table.md @@ -1,6 +1,6 @@ -# odps ddl +# odps table -> Run ddl task in ODPS (Open Data Processing Service). +> Create and modify tables in ODPS (Open Data Processing Service). - Create a table with partition and lifecycle: