Forum Discussion
Ara_Karapetyan
5 years agoHelper I
Difficulty with formulas
Hi everyone. I am new in Power BI and experience difficulties. I have 2 tables. First one contains one column with unic numbers. The second one contains 3 columns: number_from, number_to , text_s...
- 5 years ago
If you want a measure, something like this:
MeasureW = VAR _num = SELECTEDVALUE(TableOne[Column1]) RETURN CALCULATE(MIN(TableTwo[text_string]) , FILTER(TableTwo, TableTwo[number_from] <= _num && TableTwo[number_to] > _num ))You would pull the number column from the first table on to a table visual, then add the measure.
Let me know how it goes.
Also, next time please post data and desired result for faster answers.
HotChilli
5 years agoCommunity Champion
If you want a measure, something like this:
MeasureW = VAR _num = SELECTEDVALUE(TableOne[Column1])
RETURN
CALCULATE(MIN(TableTwo[text_string]) ,
FILTER(TableTwo, TableTwo[number_from] <= _num && TableTwo[number_to] > _num ))
You would pull the number column from the first table on to a table visual, then add the measure.
Let me know how it goes.
Also, next time please post data and desired result for faster answers.
- Ara_Karapetyan5 years agoHelper I
Thanks a lot! Works great!
Do you think it will work for calculated column?
- Ara_Karapetyan5 years agoHelper I
Thanks! Works!
Is there a possibility to do the same in Power Query?