Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
lamp38
New Member

Count of Rows which Contain Term?

This seems like it should be really simple, but I'm having a difficult time finding the answer.  

 

I have a bunch of survey responses from from an testing group that I want to organize:

 

  1. One of the columns in this data set is the users feedback, which is a string of text the user provided
  2. I want to be able to show a show a visual which shows the number of complaints which contain a given term (slow, frozen, crash, etc.).  

  3. Example: Total 1000 responses.  200 contain "slow",  5 contain "frozen", 5 contain "crash". 

 

For the purpose of this question you can assume my data set has two columns, responder age and feedback string.

(Some feedback strings may contain more than one of my key terms.) 

 

Thanks!

6 REPLIES 6
Ashish_Mathur
Super User
Super User

Hi,

 

Sounds like an interesting one to solve.  Share some data and show the expected result.  Especially show cases where the feedback string has multiple key terms and your expected result for those cases.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Imagine we have the following rows: 

 

  1. Complaint 1: "App is very slow." 
  2. Complaint 2: "App loads slowly." 
  3. Compaint 3: "The app was very slow, and then crashed." 

I have to be able to summarize the data as follows: 

  • Count (slow) = 3
  • Count (crashed) = 1

Hi,

 

See if my solution here helps - Analyse free flowing text data or user entered remarks from multiple perspectives.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Hi @lamp38

 

Try this:

 

1. Create a one-column table Terms in which you have the terms you want to look for

2. Place Terms[Term] on the rows of a matrix visual

3. Place this measure in values of the matrix:

 

 

Measure =
VAR _CurrentTerm =
    SELECTEDVALUE ( Terms[Term] )
RETURN
    COUNTROWS (
        FILTER ( Table1, FIND ( _CurrentTerm, Table1[feedback string], 1, 0 ) > 0 )
    )

 

v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @lamp38,

 

Have you solved your problem?

 

If you have solved, please always accept the replies making sense as solution to your question so that people who may have the same question can get the solution directly.

 

If you still need help, please share some data sample and your desired output so that we could get the solution more quickly.

 

Best  Regards,

Cherry

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
AlB
Super User
Super User

Hi @lamp38

 

If you place a matrix visual in your report and set ' feedback string' in the rows and also in values and select to summarize as 'Count' you should get something like what you are describing

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.