I am trying to create a column to see if a keyword is shared between 2 accounts on power bi. Like the example below. Bold is the result column required
Account Search Keyword Shared Keyword
Account A abc Yes
Account B abc Yes
Account A def No
Account B ghi Yes
Account A ghi Yes
Account A abc Yes
Account A abc Yes
Account A def No
Account B ghi Yes
Account A ghi Yes
The keyword can occur multiple times in the same account. I tried the following code but am getting error "A circular dependency has been detected: 'Table'[Search keyword]"
Shared Keyword =
var AccA = CALCULATE(VALUES('Table'[Search keyword]),FILTER('Table','Table'[Account (groups)]="Account A"))
var AccB = CALCULATE(VALUES('Table'[Search keyword]),FILTER('Table','Table'[Account (groups)]="Account B"))
return
if(AccA=AccB,"Yes","No")
Please help me resolve this