Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Counting number of words in a list in a sentence

oerdem19
7 - Meteor

Hi,

I need to count occurrence specific words (using a list) in a sentence. My list has over 2000 words in it.

I tried to use REGEX_CountMatches but was not successfull.

Any ideas of how to do it?

 

Here is a sample of word list:

"WORSEN
WORSENED
WORSENING
WORSENS
WORST
WORTHLESS

WRITEDOWN
WRITEDOWNS
WRITEOFF
WRITEOFFS
WRONG
WRONGDOING
WRONGDOINGS
WRONGFUL
WRONGFULLY
WRONGLY"

Here is a sample of sentence list:

Last evening, Graco released fourth quarter results, with sales totaling $349 million, an increase of 7% from the prior year.
To note, the fiscal fourth quarter of 2016 included 14 weeks as compared to 13 weeks in 2015.
On a U.S. GAAP basis, we realized a quarterly loss of $104 million.
Our fourth quarter included a noncash charge for the impairment of goodwill and intangible assets related to our Oil and Natural Gas business.

2 REPLIES 2
aatalai
14 - Magnetar

@oerdem19 does the attached workflow help?

oerdem19
7 - Meteor

Works great, Thank you.

Labels