Boolean logic in K2 [blackpearl] rules
Hi all,
Welcome to the first post on the new Pitchblack UK and Europe consulting blog. Over the coming months you'll find useful information here from the UK and Europe consulting front-lines. Information on best practices, ways to solve particular business scenarios and other tips we come across. Here's a quick tip to get the ball rolling.
Some time ago I put together some training to cover of process design elements such as parallel activities and the like during this I noticed a neat way to create some of the more complicated logic I required. As you'll all most likely know we need to use preceding rules to merge our parallel activities back in to a single line of execution. What isn't always obvious is how one can easily construct more complicated boolean expressions than simple AND, OR and XOR operations with just two terms. Contrast the difference between:
(A == True and B == True) or C == True
As opposed to:
A == True and (B == True or C == True)
Clearly they are both viable conditions but how would you model this in the K2 [blackpearl]. Well, the answer is - easily. What is sometimes missed is the Indent functions in the rule designer windows. Compare the above examples with the screen shots below:
(A == True and B == True) or C == True

A == True and (B == True or C == True)
Anyway - I hope you enjoy factoring in some logic complicated enough George Bool himself proud! Add this blog to your RSS feeds to keep up to date with our future posts.
Ashley