New Ranks & Badges For The Community!
Notice something different? The ranks and associated badges have gone "Star Fleet". See what they all mean HERE
Highlighted
Cadet 1st Class Cadet 1st Class
Cadet 1st Class
174 views

Is !(value == a || value == b) an unsupported use case for the ! operator?

Jump to solution

My use case was when you want to have part of the condition check for one value and the other make sure something else is not null or an empty string.  To me, it made sense to write it this way.

If ${x==y && !(value == null || value == '')}

But it didn't work till I changed it to use this format

If ${x==y && value != null && value != ''}

Is using the ! operator in the way I first tried an unsupported use case?

0 Likes
1 Solution

Accepted Solutions
Highlighted
Vice Admiral Vice Admiral
Vice Admiral

Hi @DCaswell,

We've been using this syntax for some time and it's working fine. From the top of my head I would check entity vs current_update and where the rules is positioned.

BR,

Svilen

View solution in original post

0 Likes
3 Replies
Highlighted
Vice Admiral Vice Admiral
Vice Admiral

Hi @DCaswell,

We've been using this syntax for some time and it's working fine. From the top of my head I would check entity vs current_update and where the rules is positioned.

BR,

Svilen

View solution in original post

0 Likes
Highlighted
Micro Focus Expert
Micro Focus Expert

Hello,

The syntax is as well used in several out of the box business rules.

Have you tried to run the workflow debugger to confirm if the issue comes from the condition evaluation result being incorrect or the rule itself has an issue (doesn't execute correctly, it is not in the right sequence and another rule coming after overrides the result, etc)?

Best regards,

Brindusa

0 Likes
Highlighted
Cadet 1st Class Cadet 1st Class
Cadet 1st Class
That helped, thanks.
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.