Logic comparison != of type string - returns test string - VisualCron - Forum

Community forum

Stefan Chivers
2020-01-15T12:23:48Z
Hi team,

Using VisualCron 8.3.3 and 8.3.1 the "{LOGIC(If|String" formula with operator != returns the test string from the first parameter rather than one of the values from the last two parameters. This happens regardless of whether the strings match. So for example:

{LOGIC(If|String|Test string|!=|Test string|String is not matching|String is matching)}
Returns "Test string"

{LOGIC(If|String|Test string|!=|Test strings|String is not matching|String is matching)}
Returns "Test string"

I would expect these examples to return "String is matching" and "String is not matching" respectively.

Thanks,
Stefan
thomas
2020-01-15T15:02:09Z
Yeah this is clearly a bug.
Gary_W
2020-01-15T15:06:55Z
Yikes! That exists in 8.5.5 too. I can't believe that hasn't been found until now. The equality comparison seems to be ok. How did this make it through testing?
Joey S
2020-01-15T16:27:56Z
Your variable is wrong OR it is wrong in the app

{LOGIC(If|String|Test string|!=%|Test string|String is not matching|String is matching)}

NOT
{LOGIC(If|String|Test string|!=|Test string|String is not matching|String is matching)}

You are missing the % after the !=
Joey S
2020-01-15T16:29:03Z
oddly enough in 8.5.5 there is a typo in the default example

{LOGIC(If|String|Test|!=%|Test string|Does not contain stringf|Contains string)}

"stringf" should lose the "f" I am guessing

thomas
2020-01-15T20:31:25Z
I assume the % must be a wildcard, so that !=% would be similar to NOT LIKE in sql. I think it is simply a bug that should have been caught by unit tests

Support
2020-01-16T09:28:34Z
Thanks for the report.

For the next build we have fixed return of the result values for:
{LOGIC(If|String|Test string|!=|Test string|String is not matching|String is matching)}

And corrected "stringf" to "string".
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Scroll to Top