# Add option for job \`requires\` to be or-ed instead of and-ed

**URL:** <https://discuss.circleci.com/t/add-option-for-job-requires-to-be-or-ed-instead-of-and-ed/39222>\
**Category:** Product Feedback\
**Tags:** workflow, circle-yml\
**Created:** [February 23, 2021, 1:13pm UTC](https://discuss.circleci.com/t/add-option-for-job-requires-to-be-or-ed-instead-of-and-ed/39222 "2021-02-23T13:13:09Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![yannCI](https://sea2.discourse-cdn.com/circleci/user_avatar/discuss.circleci.com/yannci/32/24866_2.png) [@yannCI](https://discuss.circleci.com/u/yannCI)\
**Post date:** [August 4, 2021, 11:12pm UTC](https://discuss.circleci.com/t/add-option-for-job-requires-to-be-or-ed-instead-of-and-ed/39222/4 "2021-08-04T23:12:09Z")

</div>

👋 Hi @yousefhamza,

Maybe you could use the same logic as [this workaround](https://discuss.circleci.com/t/workaround-run-jobs-sequentially-regardless-of-the-outcome-of-the-required-jobs/40807) 🤔

In your case though, the loop in the `waiter` job would be slightly different:

```auto
      - run: |
          until [[$(curl --location --request GET "https://circleci.com/api/v2/workflow/$CIRCLE_WORKFLOW_ID/job" --header "Circle-Token: $CCI_TOKEN"| jq -r '.items[]|select(.name == "job1" or .name == "job2")|.status' | grep -c "success") -gt 0 ]]; do
            sleep 1
          done

```

And then your workflow would be:

```auto
workflows:
  version: 2
  build-test-and-generate-binary:
    jobs:
      - job1
      - job2
      - waiter
      - job3:
          type: approval
          requires:
            - waiter
      - job4:
          requires:
            - job3

```

With the above configuration, `job3` will start as soon as either `job1` or `job2` finishes successfully.

---

_[View the full topic](https://discuss.circleci.com/t/add-option-for-job-requires-to-be-or-ed-instead-of-and-ed/39222)._
