Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreWe've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now
Hi
Looking for assistance with a measure. I have a a number of tables, 1 with customer review data and others with keywords that could indicate a particular sentiment. I would like to run a count on the review column (Merchant[review] to give me a hit count for the words in the reference tablesClinicalSentiment[Language].
Advice appreciated!
Mark
Solved! Go to Solution.
Hi @markhay,
You could new a calculated table via this formula:
CrossJoin Table =
FILTER (
ADDCOLUMNS (
CROSSJOIN ( Merchant, PositiveSentiment ),
"Column1", IF ( ISERROR ( FIND ( [Language], [review] ) ), 0, 1 )
),
[Column1] = 1
)
Please be aware that FIND function is case-sensitive.
Best regards,
Yuliana Gu
Hi @markhay,
Please share sample data, including detailed records in Merchant and ClinicalSentiment and table relationship. Also show us your desired output so that I can test for you.
Regards,
Yuliana Gu
Thanks for coming back to me There are no existing relationships between the Merchant and Sentiment Tables. Samples below of the main table and one of the tables containing the sentiment words. From the example I would expect rows B, E & F to trigger the count:
Merchant Table
| name | review |
| A | Brilliant Service throughout |
| B | Caring and competent |
| C | Made us both feel at ease |
| D | They gave us several options on next steps and costs, with no expectation either way. |
| E | Scott was very helpfull and has gone above & beyond yo support us. Fantastic service!! |
| F | Excellent service |
PositiveSentiment Table
| Language |
| compassion |
| caring |
| care |
| communication |
| kind |
| helpful |
| staff |
| great |
| grateful |
| happy |
| save |
| saved |
| friendly |
| excellent |
Intended Outcome
| Category | Jan | Feb | Mar |
| Positive Sentiment | 8 | 23 | 56 |
Appreciate your help
Hi @markhay,
You could new a calculated table via this formula:
CrossJoin Table =
FILTER (
ADDCOLUMNS (
CROSSJOIN ( Merchant, PositiveSentiment ),
"Column1", IF ( ISERROR ( FIND ( [Language], [review] ) ), 0, 1 )
),
[Column1] = 1
)
Please be aware that FIND function is case-sensitive.
Best regards,
Yuliana Gu
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 53 | |
| 37 | |
| 35 | |
| 19 | |
| 17 |
| User | Count |
|---|---|
| 74 | |
| 69 | |
| 39 | |
| 35 | |
| 23 |