Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello there,
I'd like to explain what i'm actually working on so it would be easier to find the solution I believe.
I have scenarios and there are two quotes red team and yellow team. Each scenario has variables and their values. Column structure:
scenario_id | variable_id | quantity_type | quantity | unit_cost | price | team_name |
0001_abcd_99 | XX123 | lbs | 10 | 0.5 | 5 | teamA |
0001_abcd_99 | XX123 | lbs | 20 | 0.4 | 8 | teamB |
and I get the values by these functions:
Solved! Go to Solution.
please try
measure_test =
SUMX (
DISTINCT ( 'Appended_Table'[scenario_id] ),
INT ( [avg variance between A & B] > 0.10 )
)
SUMX iterates each scenario available in the current filter context (in the total cell for example, the scenarios available are the scenarios defined by the outer filter context), and evalute if the measure is > 0.1
INT converts TRUE to 1 and FALSE to 0
SUMX will act as a counter adding 1 for each true iteration thus counting the scenarios that fulfill the condition.
please try
measure_test =
SUMX (
DISTINCT ( 'Appended_Table'[scenario_id] ),
INT ( [avg variance between A & B] > 0.10 )
)
User | Count |
---|---|
25 | |
11 | |
8 | |
6 | |
6 |
User | Count |
---|---|
27 | |
13 | |
11 | |
9 | |
6 |