> For the complete documentation index, see [llms.txt](https://documentation.astera.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://documentation.astera.com/astera-data-stack-v10/faqs/workflows/how-do-i-trigger-a-task-if-at-least-one-of-a-set-of-tasks-fails.md).

# How do I trigger a task if at least one of a set of tasks fails?

Triggering an error notification email if one or more tasks fail from a set of multiple tasks is a common use case. Multiple incoming workflow links to a workflow task object by default operate with AND combination logic. &#x20;

In the following workflow, if all of the linked tasks, RunDataflow, RunDataflow1, and RunDataflow2, fail, the SendMail task will be triggered.&#x20;

<figure><img src="https://3083465318-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FsR50Wa7EwZGlmPSAMkkf%2Fuploads%2FoY25aExLFdsRziHXOAep%2FWorkflow-1.png?alt=media&amp;token=1e2846db-71e4-49b4-be6d-4cb208824046" alt="" width="563"><figcaption></figcaption></figure>

If you want SendMail to be triggered if one or more tasks fail, you can use the OR object. With this flow, if one or more of the dataflows fail, the OR object will return a True, and the error notification email will be triggered.

<figure><img src="https://3083465318-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FsR50Wa7EwZGlmPSAMkkf%2Fuploads%2Fy574heWArCBTl3QQmeWs%2FWorkflow-2.png?alt=media&amp;token=9348eb03-b8a3-4161-b02c-c2db565007dd" alt="" width="563"><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://documentation.astera.com/astera-data-stack-v10/faqs/workflows/how-do-i-trigger-a-task-if-at-least-one-of-a-set-of-tasks-fails.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
