Genesys Cloud (formerly PureCloud)

Discussion Thread View
Expand all | Collapse all

Searching list of keywords from a data table - Email routing

  • 1.  Searching list of keywords from a data table - Email routing

    Posted 03-06-2020 13:20
    I have a requirement to manage a list of keywords to search in the subject or body of an email from a data table so this can be easily updated by the end user without editing the email flow in Architect.

    I've tried the following.

    Creating a data table with a column for each key word and then using an expression contains(email.message.body,flow.word1) or expression contains(email.message.body,flow.word2)

    Data Table
    This works but I have to account for blank data and I have to fix the number of words available.

    I also tried something a bit odd which was adding an expression inside a string to use. This had two issues. 1 is that quotes were modified to  \" and as far as I can see when I used a combination of the two so replaced the quotes with flow.word1 it still failed so I assume this is not possible.

    Data Table 2

    Has any one come up with a way to achieve this? I've looked at makelist but I don't think that will work in this case. My other option is to send the email body or subject to an external service possibly by lambda to Amazon Comprehend.
    #DigitalChannels
    #Routing(ACD/IVR)

    ------------------------------
    Richard Chandler
    Conn3ct
    ------------------------------


  • 2.  RE: Searching list of keywords from a data table - Email routing

    Top 25 Contributor
    Posted 03-07-2020 14:27
    My choice would be a list of words divided by a pipe and then use a loop in the Email flow to parse through the pipe-delimited field a word at a time with the same search parameter each time until you are out of words.  Saves worrying about blank fields or adding fields and allows any number of words to be used.

    So you would have:

    Sales                    Sales|Richard|Mark|ETC                           This is my custom autoreply



    ------------------------------
    Robert Wakefield-Carl
    Avtex Solutions, LLC
    Contact Center Innovation Architect
    robertwc@avtex.com
    https://www.Avtex.com
    https://RobertWC.Blogspot.com
    ------------------------------



  • 3.  RE: Searching list of keywords from a data table - Email routing

    Posted 03-09-2020 05:49
    Thanks Robert,

    Can you please share a copy of the makelist, count and contains expressions used please?

    ------------------------------
    Richard Chandler
    G3 Comms Ltd
    ------------------------------



  • 4.  RE: Searching list of keywords from a data table - Email routing

    Posted 13 days ago
    hi there,
    please advise if you have received the below and if you managed to get this working as i am faced with same issue?

    Can you please share a copy of the makelist, count and contains expressions used please?

    ------------------------------
    Reginald Sheraton
    Bytes Systems Integration a Division of Altron
    ------------------------------



  • 5.  RE: Searching list of keywords from a data table - Email routing

    Top 25 Contributor
    Posted 13 days ago
    Edited by Robert Wakefield-Carl 13 days ago
    When you read in the Data Table, you will get a string.   You use the Make List - MakeList(DataTableLookup) - to split that string into multiple elements in a collection and then use Count(ConnectionName) to get the number of elements in the collection.








    ------------------------------
    Robert Wakefield-Carl
    Avtex Solutions, LLC
    Contact Center Innovation Architect
    robertwc@avtex.com
    https://www.Avtex.com
    https://RobertWC.Blogspot.com
    ------------------------------