Forum Discussion
bbbt123
6 years agoHelper I
help with calculated column
Hello, I need help with a calculated column. I have a table, call it "Table1" with unique values per category, see example below: category value a 30 b 40 c 50 Then I have ...
- 6 years ago
I am thinking perhaps:
Column in Table2 = VAR __Category = [category] VAR __MinWeek = MINX(FILTER(ALL('Table2'),[category]=__Category),[week num]) RETURN IF([week num] = __MinWeek,LOOKUPVALUE('Table1'[value],'Table1'[category],__Category),BLANK())
amitchandak
6 years agoSuper User
Create these two new columns in table 2
Count = countx(filter(table2,table2[category]=earlier(table2[category]) && table2[week num] <=earlier(table2[week num])),table2[week num])
from table 1 = maxx(filter(table1,table2[category]=(table1[category]) && table2[Count]=1),table1[value])
Appreciate your Kudos.