Survey banner
The Dataiku Community is moving to a new home! We are temporary in read only mode: LEARN MORE

Custom trigger scenario

Level 2
Custom trigger scenario


I would like to execute a scenario according to a custom trigger: after a scenario of another project and if it is Monday.
What is the best way to do this?

0 Kudos
1 Reply

Hi @lau_sch,

From my understanding, you want the scenario to run after running another scenario, but only if it's currently Monday, correct?

You could accomplish this by using a custom Python trigger that checks for both of your conditions, but I think it would be easier if you used the following strategy instead:

  1. Add a "Run another scenario" step to the scenario that you want to run first, and configure it to run the second scenario that you want to be triggered.
  2. Use the following custom condition for the step:
    datePart(now(), "dayofweek") == 1​

    This will cause the step to run only if the current weekday is Monday (for more information, see Formula language | Date functions).






0 Kudos