How to use already deployed DMN output as Input for other DMNs

Hi there,

I would like to use the output of one DMN, which is already deployed,
as an input for several other DMNs.

Is it possible that I can use this like via DMN key, id or output name in input expression field?
Or should I get the output via API in a script task and put it in as an input?

Best Regards,
Hyunjin

In this example process-models/dmn/dinnerDecision at master · rob2universe/process-models · GitHub
I used the original dmn from Camunda DMN-Simulator and split it into two files, which were then used combined in the bpmn process.

The important part is to make sure the business rule task define their output variables correctly.
The first task has to name its output desiredDish because this is the input required for the second task.

image

<bpmn:sequenceFlow id="SequenceFlow_1ombes7" sourceRef="Task_0kc5hdh" targetRef="EndEvent_0o5pt5b" />
<bpmn:businessRuleTask id="Task_1kf1y1r" name="Dish decision" camunda:resultVariable="desiredDish" camunda:decisionRef="dish" camunda:mapDecisionResult="singleEntry">
  <bpmn:incoming>SequenceFlow_110ipo2</bpmn:incoming>
  <bpmn:outgoing>SequenceFlow_0b9etzq</bpmn:outgoing>
</bpmn:businessRuleTask>
<bpmn:businessRuleTask id="Task_09satot" name="Beverage decision" camunda:resultVariable="beverages" camunda:decisionRef="beverages" camunda:mapDecisionResult="collectEntries">
  <bpmn:incoming>SequenceFlow_0b9etzq</bpmn:incoming>
  <bpmn:outgoing>SequenceFlow_0ezgiqx</bpmn:outgoing>
</bpmn:businessRuleTask>

Hi there,

thank you for your reply.
I already used cases like your example :slight_smile:
What I asked was, whether you can get an output from other dmn which is not in the process.

Can you help me here too?

Have you tried using the decision service in an expression?

What would you gain from not including a rules task in the process to call the existing dmn by key and instead hide this invocation in an input expression field?
The approach certainly does not serve the clarity of the process model well.

1 Like

How to use the output of the dmn in a service task. we have the desiredDish as a output and if a want use the output in the service task to check a condition an then return something based on the condition.
EX: In Service task:
if(desiredDish.equals(“something”)){
do something
}