# Advanced Retention Rules

Though every Snapshot Policy has a default record retention rule, it is often convenient to have a custom retention rule for specific tables. Example:

* By default, retain records in a snapshot for 90 days.
* Retain Account, Contact, and Opportunity records for 365 days.
* Retain Case records for 2 years.
* Do not retain EmailMessage records.

The following two screens illustrate how to set up this policy.

![](/files/BlG2qpdAUuU4PI4vtKdj)

Clicking on the *Advanced* button launches an editor to override the default record retention rule. The following example sets up the scenario described at the top of this page.

![](/files/YTXVDSeJdUHE0PDgDEQX)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://learn.capstorm.com/reference/archive-tab/archive-policy-editor/advanced-retention-rules.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
