How to pass Boolean variable from one pipeline to another pipeline when using execute pipeline activity?

JasonW-5564 161 Reputation points
2021-10-05T18:23:00.687+00:00

I have a parent pipeline that has 2 children pipelines that is executes via an execute pipeline activity. Child 1 pipeline sets a Boolean variable that it uses in an "if" activity to send a notification as the last step of that pipeline. Now back in the parent pipeline, if that variable is true at the end of child1, I do not want to execute child2 pipeline. How can I accomplish this? Seems there must be an easy way that I am missing! Thanks!

137874-image.png

Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
11,623 questions
0 comments No comments
{count} votes

Accepted answer
  1. JasonW-5564 161 Reputation points
    2021-10-05T21:15:43.793+00:00

    I believe I have this solved. A bit confusing, but will try to explain...

    1. I created a shell pipeline and created a bool parameter in it.
    2. At the end of Child 1 Pipeline, I removed my 'If' Activity checking the bool variable (and the if true send notification activity).
    3. I replaced that 'If' in Child1 with an execute pipeline task and had it execute my new shell pipeline. I set the bool parameter (shows up when I select the pipeline in the Settings tab) = to my Child1 bool variable. <--This is how to pass the value out of the pipeline.
    4. In the shell pipeline, I added an 'If' and have it check the pipeline parameter from the first step. When true it sends the notification (removed from Child1 pipeline in second step). If false, I added an execute pipeline task and set it to execute Child2 pipeline.

    Hope that makes sense and helps someone....

    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.