呼叫UpdateTable更新MaxCompute表。
目前該API介面已標記為棄用。
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| IsView |
integer |
否 |
是否為視圖,包括 0(否)和 1(是)。該欄位已廢棄,請勿使用。 |
0 |
| Visibility |
integer |
否 |
表的可見性,包括 0(對所有成員不可見)、1(對所有成員可見)和 2(對工作空間成員可見)。 |
1 |
| LifeCycle |
integer |
否 |
表的生命週期,單位為天。生命週期為空時,表示永久儲存。 |
10 |
| CategoryId |
integer |
否 |
關聯的類目 ID。 |
101 |
| LogicalLevelId |
integer |
否 |
邏輯層級 ID。 |
101 |
| PhysicsLevelId |
integer |
否 |
物理層級 ID。 |
101 |
| ExternalTableType |
string |
否 |
外表的類型,包括 0(OSS)、1(TableStore)、2(Volume)和 3(MySQL)。該欄位已廢棄,請勿使用。 |
1 |
| Location |
string |
否 |
外表的儲存位址。該欄位已廢棄,請勿使用。 |
location |
| ProjectId |
integer |
否 |
DataWorks 工作空間的 ID。您可以登入 DataWorks 主控台取得工作空間 ID。 |
101 |
| TableName |
string |
是 |
MaxCompute 表名稱。 |
abc |
| Endpoint |
string |
否 |
MaxCompute Endpoint。不填時,預設取專案對應的 Endpoint。 |
odps:// |
| EnvType |
integer |
否 |
DataWorks 工作空間的環境,包括 0(開發環境)和 1(生產環境)。 |
1 |
| AppGuid |
string |
否 |
MaxCompute 專案的唯一識別碼,格式為 odps.{projectName}。 |
odps.test |
| CreateIfNotExists |
boolean |
否 |
表是否存在:
該欄位已廢棄,請勿使用。 |
true |
| HasPart |
integer |
否 |
需要更新的 MaxCompute 表是否為分區表,包括 0(否)和 1(是)。該欄位已廢棄,請勿使用。 目前程式碼會根據 Column.N.isPartitionCol 參數判斷 MaxCompute 表是否為分區表,當 Column.N.isPartition 參數取值為 1 時,則認為 MaxCompute 表為分區表。 |
0 |
| Comment |
string |
否 |
備註資訊。 |
备注 |
| Schema |
string |
否 |
表 Schema 資訊。在 ODPS,當您啟動了三層模型時需要填寫 Schema 資訊。 |
default |
| Columns |
array<object> |
否 |
欄位列表 |
|
|
object |
否 |
傳回物件 |
||
| ColumnNameCn |
string |
否 |
欄位的中文名稱。 |
中文 |
| ColumnName |
string |
是 |
欄位的名稱。 |
abc |
| Comment |
string |
否 |
欄位的備註。 |
备注 |
| ColumnType |
string |
是 |
欄位的類型,請參見 MaxCompute 支援的欄位類型。 |
string |
| SeqNumber |
integer |
否 |
欄位的序號。如果欄位為分區欄位,則不支援設定 Columns.N.SeqNumber。 |
1 |
| Length |
integer |
否 |
欄位的長度。 |
10 |
| IsPartitionCol |
boolean |
否 |
是否為分區欄位,包括 0(否)和 1(是)。 |
0 |
| Themes |
array<object> |
否 |
欄位列表 |
|
|
object |
否 |
傳回物件 |
||
| ThemeId |
integer |
否 |
關聯的主題 ID。 |
101 |
| ThemeLevel |
integer |
否 |
主題 ID 對應的層級。 |
101 |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
|
object |
傳回物件 |
||
| RequestId |
string |
請求 ID。 |
abcde |
| TaskInfo |
object |
請求任務的資訊。 請求任務提交成功後,會被分為多個子任務有序執行。當前子任務執行成功後,才會繼續執行下一個子任務,所有子任務執行完畢,該請求任務結束。如下情況,請求任務會終止,您需要根據錯誤碼資訊解決問題後重新發起請求任務:
|
|
| Status |
string |
當前執行的子任務的狀態資訊。取值如下:
|
success |
| NextTaskId |
string |
即將執行的子任務 ID。如果該欄位為空,則表示所有子任務均已結束。您可以使用取得到的 ID,從 GetDDLJobStatus 介面查詢對應子任務的狀態。 |
abc1 |
| TaskId |
string |
當前執行的子任務 ID。 |
abc |
| Content |
string |
當前子任務的執行狀態詳細資訊。具體如下:
|
success |
樣本
正常返回樣本
JSON格式
{
"RequestId": "abcde",
"TaskInfo": {
"Status": "success",
"NextTaskId": "abc1",
"TaskId": "abc",
"Content": "success"
}
}
錯誤碼
|
HTTP status code |
錯誤碼 |
錯誤資訊 |
描述 |
|---|---|---|---|
| 500 | InternalError.System | An internal system error occurred. Try again later. | |
| 500 | InternalError.UserId.Missing | An internal system error occurred. Try again later. | |
| 403 | Forbidden.Access | Access is forbidden. Please first activate DataWorks Enterprise Edition or Flagship Edition. | |
| 429 | Throttling.Api | The request for this resource has exceeded your available limit. | |
| 429 | Throttling.Api.Risk | The request for this resource has exceeded your daily available limit. | |
| 429 | Throttling.System | The DataWorks system is busy. Try again later. | |
| 429 | Throttling.User | Your request is too frequent. Try again later. |
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。