Data Quality ルールを更新します。
この API は廃止されました。一時的にアクセス可能ですが、更新やバグ修正対応は一切行われません。代わりに dataworks-public(2024-05-18) - UpdateDataQualityScan への移行を推奨します。より強化された機能に加え、サポートも引き続きご利用いただけます。
操作説明
You must purchase DataWorks Basic Edition or above to use this feature.
今すぐお試しください
テスト
RAM 認証
リクエストパラメーター
|
パラメーター |
型 |
必須 / 任意 |
説明 |
例 |
| Id |
integer |
必須 |
ルール ID。 |
100001 |
| Name |
string |
任意 |
ルール名。名前は数字、英字、中国語文字、半角または全角の句読点の組み合わせで指定できます。最大値は 255 文字です。 |
表不能为空 |
| Enabled |
boolean |
任意 |
ルールが有効かどうかを指定します。 |
true |
| Severity |
string |
任意 |
ビジネスに対するルールの重大度レベル(ページ上の強い/弱いルールに対応)。有効な値:
|
High |
| Description |
string |
任意 |
ルールの説明。最大値は 500 文字です。 |
this is a odps _sql task |
| ProjectId |
integer |
必須 |
DataWorks ワークスペースの ID。DataWorks コンソールにログオンし、ワークスペース設定項目ページでワークスペース ID を取得できます。 |
10000 |
| TemplateCode |
string |
任意 |
ルールがリファレンスするルールテンプレートの一意の識別子。 |
SYSTEM:table:table_count:fixed |
| SamplingConfig |
object |
任意 |
サンプルコレクションに必須の設定項目。 |
|
| Metric |
string |
任意 |
The name of the metric to sample. This parameter is not required when a template is used.
|
Min |
| MetricParameters |
string |
任意 |
The parameters required for sample collection. |
{ "Columns": [ "id", "name" ] , "SQL": "select count(1) from table;"} |
| SettingConfig |
string |
任意 |
The runtime parameter setting statements to be inserted and executed before the actual sampling statements. The maximum length is 1,000 characters. Only MaxCompute is supported. |
SET odps.sql.udf.timeout=600s; SET odps.sql.python.version=cp27; |
| SamplingFilter |
string |
任意 |
The condition used to apply secondary filtering on data that is not of interest during sampling. The maximum length is 16,777,215 characters. |
id IS NULL |
| CheckingConfig |
object |
任意 |
サンプル検証の設定項目。 |
|
| Type |
string |
任意 |
The threshold calculation method. This parameter is not required when a template is used.
|
Fixed |
| ReferencedSamplesFilter |
string |
任意 |
Some types of thresholds require querying reference samples and then aggregating the values of those reference samples to derive the threshold used for comparison. An expression is used here to indicate how the reference samples are queried. |
{ "bizdate": [ "-1", "-7", "-1m" ] } |
| Thresholds |
object |
任意 |
The threshold settings. |
|
| Expected |
object |
任意 |
The expected threshold settings. |
|
| Operator |
string |
任意 |
The comparison operator. Valid values:
|
> |
| Value |
string |
任意 |
The threshold value. |
100.0 |
| Expression |
string |
任意 |
The threshold expression. The volatility type rule must use an expression to represent the volatility threshold. For example:
You can also use expressions to configure thresholds for fixed-Value rules. If you configure them at the same time, the expression priority is higher than Operator and Value. |
$checkValue <= 0.01 |
| Warned |
object |
任意 |
The threshold settings for normal warnings. |
|
| Operator |
string |
任意 |
The comparison operator. Valid values:
|
> |
| Value |
string |
任意 |
The threshold value. |
100.0 |
| Expression |
string |
任意 |
The threshold expression. The volatility type rule must use an expression to represent the volatility threshold. For example:
You can also use expressions to configure thresholds for fixed-Value rules. If you configure them at the same time, the expression priority is higher than Operator and Value. |
$checkValue > 0.01 |
| Critical |
object |
任意 |
The threshold settings for critical warnings. |
|
| Operator |
string |
任意 |
The comparison operator. Valid values:
|
> |
| Value |
string |
任意 |
The threshold value. |
100.0 |
| Expression |
string |
任意 |
The threshold expression. The volatility type rule must use an expression to represent the volatility threshold. For example:
You can also use expressions to configure thresholds for fixed-Value rules. If you configure them at the same time, the expression priority is higher than Operator and Value. |
$checkValue > 0.05 |
| ErrorHandlers |
array<object> |
任意 |
Data Quality ルール検証の発行ハンドラのリスト。 |
|
|
object |
任意 |
An issue handler for data quality rule verification. |
||
| Type |
string |
任意 |
The handler type.
|
SaveErrorData |
| ErrorDataFilter |
string |
任意 |
For a custom SQL rule, you must specify the SQL used to filter problematic data. |
SELECT * FROM tb_api_log WHERE id IS NULL |
レスポンスフィールド
|
フィールド |
型 |
説明 |
例 |
|
object |
The returned data. |
||
| RequestId |
string |
Id of the request |
691CA452-D37A-4ED0-9441 |
| Success |
boolean |
Indicates whether the update was successful. |
true |
例
成功レスポンス
JSONJSON
{
"RequestId": "691CA452-D37A-4ED0-9441\n",
"Success": true
}
エラーコード
完全なリストについては、「エラーコード」をご参照ください。
変更履歴
完全なリストについては、「変更履歴」をご参照ください。