Search() function Issue

 Hi 

I'm new to appian.Please help me out of this problem

"Requirement: When I receive an email with subject as "Hello World" I should delete the process.

So I applied a condition in xor node like "search("Hello World",pv!incomingSubject)>0" 

If this condition satisfies it moves to deletion Process node.

but the problem is when the subject's length crosses above 70 it is not satisfying the above condition.

eg(XXXX YYYYYYY AAAAA BBBBBBBBBBBB: LMI Aerospace (USA): Hello World QQQQQQQQ SAMPLE SUBECT LINE)

The above subject contains "Hello World" but it is not working.

Note : incomingSubject (Text)

  Discussion posts and replies are publicly visible

Parents Reply
  • Hi,

    Can you use this code and check

    with(
    local!a:split("XXXX YYYYYYY AAAAA BBBBBBBBBBBB: LMI Aerospace (USA): Hello World QQQQQQQQ SAMPLE SUBECT LINE"," "),
    local!b:wherecontains({"Hello","World"},local!a),
    local!b)

    I am trying to split all the data with split and making it as an array and finding the indices in the array,

    count the index values, if the index value count is >0 then route it to delete process.
Children