Supplies are limited. Contact info@espc.tech right away to save your spot before the conference sells out.
Get your discountScore big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount
I would like to create a measure "forecast" by checking the quarter selected and display different set of values.
The result for each quarter is correct as shown in table below. however the total is blank. how do i go about get the total of Quarter 1 to 4.
thanks.
Quarter | 1 | 2 | 3 | 4 | Total |
Forecast | Forecast | Forecast | Forecast | Forecast | |
200 | 100 | 150 | 400 |
Solved! Go to Solution.
Hi @evez ,
You can try this-
Forecast =
IF(
HASONEVALUE(all_rates_v[fiscal_quarter]),
SWITCH(
TRUE(),
VALUES(all_rates_v[fiscal_quarter]) = 1, [Actual],
VALUES(all_rates_v[fiscal_quarter]) = 2, [Actual],
VALUES(all_rates_v[fiscal_quarter]) = 3, [forecast],
VALUES(all_rates_v[fiscal_quarter]) = 4, [budget]
),
[Actual] + [Actual] + [forecast] + [budget]
)
Here HASONEVALUE checks if only one quarter is selected.
Hope this helps!
Hi @evez ,
You can try this-
Forecast =
IF(
HASONEVALUE(all_rates_v[fiscal_quarter]),
SWITCH(
TRUE(),
VALUES(all_rates_v[fiscal_quarter]) = 1, [Actual],
VALUES(all_rates_v[fiscal_quarter]) = 2, [Actual],
VALUES(all_rates_v[fiscal_quarter]) = 3, [forecast],
VALUES(all_rates_v[fiscal_quarter]) = 4, [budget]
),
[Actual] + [Actual] + [forecast] + [budget]
)
Here HASONEVALUE checks if only one quarter is selected.
Hope this helps!
@v-sdhruv thanks it works. but i change the code a bit to fit my need.
If this helped, please consider giving kudos and mark as a solution
@me in replies or I'll lose your threadconsider voting this Power BI idea
Francesco Bergamaschi
MBA, M.Eng, M.Econ, Professor of BI
@FBergamaschi thanks for your reply. but it seems not working. now the quarterly number is incorrect too. while the total is still blank. any other way to work around?
User | Count |
---|---|
12 | |
12 | |
8 | |
8 | |
6 |
User | Count |
---|---|
27 | |
19 | |
14 | |
11 | |
7 |