Forum Discussion
dosinkevic
8 years agoFrequent Visitor
CountIF text contains ID
Hello guys, I'm new to PorweBI and writing Query formulas is super hard for me. I'm trying to get same result as in GoogleSheets =COUNTIF(sales!L:L,"*"&CampaignID&"*") I have two queries: CAMPAIG...
- 8 years ago
Create a column in your CAMPAIGN table like this:
Column = VAR __tmpTable = ADDCOLUMNS(ALL(crm),"Found",FIND([id],[camp_tracker],,-1)) RETURN COUNTROWS(FILTER(__tmpTable,[Found]<>-1))
alexei7
8 years agoContinued Contributor
Hi dosinkevic,
I presume that you have the campaign id field in your "CRM" table.
If you do, then you should be able to create a measure in CRM which is just "count_sales = COUNTROWS(CRM)
Then, in a table visualisation in Power BI, bring in all the fields from your Campaign table, and the new "count_sales" measure you've just created.
Hope that helps,
Alex