Forum Discussion
NOT INVALUES is not working
- 1 year ago
Hi Fistachpl ,
Thank you for reaching out to Microsoft Fabric Community Forum.
here can calculate how many times each Sales Rep called another Sales Rep based on phone number here i have used TREATAS & LOOKUPVALUE function.
CallsToSalesReps :=
CALCULATE(
COUNTROWS(PhoneCalls),
TREATAS(VALUES(SalesRep[Phone]), PhoneCalls[RecipientNumber])
)2)
SalesRepName =
LOOKUPVALUE(
SalesRep[Name],
SalesRep[Phone], PhoneCalls[RecipientNumber]
)Regards,
Chaithanya.
Hi Fistachpl ,
Thank you for reaching out to Microsoft Fabric Community Forum.
Below are the points why in values is not working.
1.IN VALUES() requires both columns to be comparable (same data type and format) — check that the [Recipient] column and the column you're comparing from VALUES() are exactly the same type (e.g., text without extra spaces).
2.If the column in VALUES() comes from a different or merged table and there’s no relationship between that and your main table, IN VALUES() will return nothing.
3.You can use TREATAS() to apply the list of values from one table as a filter on the other
Regards,
Chaithanya.
Thanbks for more input.
1) Both are text with just a phone number in the same format 11 digits: 48123456789
2) The column in Values() Phone from SalesRep does not have a relation ship with RecipientNumber in the table PhoneCalls
3) Can You show an example?
Thank You very much !
- v-kathullac1 year ago
Community Support
Hi Fistachpl ,
Thank you for reaching out to Microsoft Fabric Community Forum.
here can calculate how many times each Sales Rep called another Sales Rep based on phone number here i have used TREATAS & LOOKUPVALUE function.
CallsToSalesReps :=
CALCULATE(
COUNTROWS(PhoneCalls),
TREATAS(VALUES(SalesRep[Phone]), PhoneCalls[RecipientNumber])
)2)
SalesRepName =
LOOKUPVALUE(
SalesRep[Name],
SalesRep[Phone], PhoneCalls[RecipientNumber]
)Regards,
Chaithanya.