Pedro Lino de Sousa

Decision Table with a String Array as the input

Discussion created by Pedro Lino de Sousa on Apr 14, 2011
Latest reply on May 9, 2011 by Jostein Ulseth

 

Hi

 

I have a requirement in a decision table and I would appreciate any help because I just don't see how will I be able to get this done.

 

As input, the table will receive a String array. In each cell condition of the table I can have multiple "or's" and/or "and's" beteween strings from a value list holder:

 

 

DiagnosticAction
CPE -Corrente
Lacete - Funcionamento
Y
DAS - NetN

 

In this particular instance example we need the behavior to be in each cell iterate the input string array and validate the condition ("Diagnostic" column) in each cell:

 

1)On the first cell if at least one of the input strings  is "CPE- Corrente" or "Lacete - Funcionamento"

2)On the second cell, validate if at least one of the input strings is "DAS - Net"

 

I have tried to put a foreach instruction on srl content of the equals in order to iterate the input array:

 

for each diagnostic in parameter1.diagnostics ( diagnostic = "<value>")

 

but in the end this instruction goes to if on the instance table:

 

if (for each diagnostic in parameter1.diagnostics ( ( ...

 

And this is wrong, of corse.

 

Can please someone help me? Any help would be appreciated.

 

Best Regards,

Pedro

Outcomes