Decision Table with multiple outputs


I have a decision table that returns two outputs based on the input values.

I'm calling this Decision table rule from a process, how can i store the result in a activity class variable?

The output of the decision table is a MAP, i could not find a compatible datatype for this in a process model.


Can someone please help?




Sunil Zacharia

  Discussion posts and replies are publicly visible

Parents Reply Children
  • Hi  i too had a similar requirement to achieve couple of months/an year ago, where we need to return array of output.

    Scenario to consider:
    (I). When we have more than one output configured, means each output can be either of same or different types, hence this returns MAP, as this deals with Key-Value pair format to differentiate the responses of their respective output. e.g (Sample response)

    Output1: {1,2,3} -> Here this output is of Number Integer (List/Array),
    Output2: myGroup1 -> Here Output2 is of type Group

    This is equivalent to the Dictionary structure. Consider, Output1 and Output2 is the name of your Output of decision Object, and this might vary based on what name you configure under your decision object.

    Now when you call this decision Object into Process model, you can hold this as following:

    1. Under Script Task Input tab, use todatasubset(rule!yourDecision) -> Store this into a AC Variable of type datasubset (as i don't want to hold this complete datasubset into PV, instead i need to hold the individual responses(Output1, Output2), depending on your requirement). Now under Output tab of this Script task, write the following:

    (a). index(ac!, "Output1", {}) -> Store this into PV of type List of Number(Integer)
    (b). index(ac!, "Output2", {}) -> Store this into PV of type Group

    Consider, datasubset is the activity class variable of type Datasubset defined under Input Tab of Script Task.

    Hope this will help you deal with Multiple output of decision Object.