Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Switch services using the Version drop-down list. Learn more about navigation.
Applies to: ✅ Azure Data Explorer
Alters the database-level extent tags retention policy. For more information, see extent tags retention policy.
Permissions
You must have at least Database Admin permissions to run this command.
Syntax
.alter database DatabaseName policy extent_tags_retention SerializedArrayOfPolicyObjects
Learn more about syntax conventions.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| DatabaseName | string |
✔️ | The name of the database for which to alter the extent tags retention policy. |
| SerializedArrayOfPolicyObjects | string |
✔️ | A serialized array of policy objects. For more information, see the extent tags retention policy. |
Example
The following command sets an extent tags retention policy for database D1. The policy causes any drop-by tags that are older than three days and any ingest-by tags that are older than two hours to be automatically dropped.
.alter database D1 policy extent_tags_retention ```[
{
"TagPrefix": "drop-by:",
"RetentionPeriod": "3.00:00:00"
},
{
"TagPrefix": "ingest-by:",
"RetentionPeriod": "02:00:00"
}
]```