Reputation: 2503
I have If condition with one expression. Activity seems to support only True and False.
I would like to have 3 different outcome. Possible values are "A", "B" or "C"
It is possible with any tool or should I have If condition inside if condition?
Upvotes: 0
Views: 1196
Reputation: 533
You may try to use Switch Activity: It could work on different possible outcomes
Sample:
I have a pipeline that assigns a value to a variable based on parameter passed during runtime
the expression in my set variable activity is:
@string(mul(int(pipeline().parameters.flagvalue),10))
I am multiplying the parameter value by 10 and assigning to a vaiable called outflag.
Then in the switch activity i am checking the value of outflag as below
In each switch case, you can have as many activities as you want.
Upvotes: 2
Reputation: 4925
You cannot have IF activity within another IF activity directly. One way is create a pipeline with 1 if activity call it in another pipeline within IF activity via execute pipeline activity. Or You can use Switch activity for multiple scenarios.
Upvotes: 0