The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hello everyone, I am getting this error when I select all in the customer slicer. How should I edit the measure below to avoid this error?
Amount =
VAR yearmonth =
VALUES ( Table1[yearmonth] )
VAR cus =
VALUES ( Table1[customer] )
VAR agent =
CALCULATETABLE(
VALUES ( Table1[customer_id] ) ,
FILTER (
Table1,
Table1[yearmonth] = yearmonth
&& Table1[customer] = cus
)
)
VAR sales =
CALCULATE (
SUM ( sales2[amount] ),
FILTER (
sales2,
sales2[customer_id]
IN agent
&& sales2[yearmonth]
IN yearmonth
&& sales2[channel] = "Bank"
)
)
RETURN
sales
Solved! Go to Solution.
@sonya7 , use in here
VAR agent =
CALCULATETABLE(
VALUES ( Table1[customer_id] ) ,
FILTER (
Table1,
Table1[yearmonth] in yearmonth
&& Table1[customer] in cus
)
)
@sonya7 , use in here
VAR agent =
CALCULATETABLE(
VALUES ( Table1[customer_id] ) ,
FILTER (
Table1,
Table1[yearmonth] in yearmonth
&& Table1[customer] in cus
)
)