Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Anonymous
Not applicable

Fixed Value at Dimension Level

Hi,

 

Here, I am struggling to calculate custom column based on another two dimensions.

In below example, I wanted to calculate the field called "Main Task Status", which has to pick up the value of Status at the each level of  "Main Task", when Category is "IT". 

And also, if the Category 'IT' is having two Sub Tasks with different Status then it should be 'Progress', other wise it should have same status.

 

 

Main TaskCategorySub TaskStatus
TIC001ITsub-001Completed
 TIC001Servicessub-002Completed
 TIC001Servicessub-003Progress
 TIC001Hardwaresub-004To Do
TIC002ITsub-005Progress
 TIC002ITsub-006Completed
 TIC002Servicessub-007Progress
 TIC002Hardwaresub-008Progress
TIC003ITsub-009Progress
 TIC003ITsub-010Progress
 TIC003Servicessub-011Completed
 TIC003Hardwaresub-012To Do

 

 

I am expecting below results in Main Task Status

 

Main TaskCategorySub TaskStatusMain Task Status
TIC001ITsub-001CompletedCompleted
 Servicessub-002CompletedCompleted
 Servicessub-003ProgressCompleted
 Hardwaresub-004To DoCompleted
TIC002ITsub-005ProgressProgress
 ITsub-006CompletedProgress
 Servicessub-007ProgressProgress
 Hardwaresub-008ProgressProgress
TIC003ITsub-009To DoTo Do
 ITsub-010To DoTo Do
 Servicessub-011CompletedTo Do
 Hardwaresub-012To DoTo Do

 

Any help is much appreciated.

 

Thanks,

Ganesh

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Is this what you want. Add as custom column

 

Main Status = 
VAR
ITComp = 
COUNTROWS(FILTER(Table1,Table1[Main Task]=EARLIER(Table1[Main Task]) && Table1[Category]="IT" && Table1[Status]="Completed"))

VAR
ITProg = 
COUNTROWS(FILTER(Table1,Table1[Main Task]=EARLIER(Table1[Main Task]) && Table1[Category]="IT" && Table1[Status]="Progress"))

VAR
ITToDo = 
COUNTROWS(FILTER(Table1,Table1[Main Task]=EARLIER(Table1[Main Task]) && Table1[Category]="IT" && Table1[Status]="To Do"))

VAR
ITAll = 
COUNTROWS(FILTER(Table1,Table1[Main Task]=EARLIER(Table1[Main Task]) && Table1[Category]="IT"))

Return
IF(ITComp = ITAll,"Completed",IF(ITProg = ITAll,"Progress",IF(ITToDo = ITAll,"To Do","Progress")))

 

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Is this what you want. Add as custom column

 

Main Status = 
VAR
ITComp = 
COUNTROWS(FILTER(Table1,Table1[Main Task]=EARLIER(Table1[Main Task]) && Table1[Category]="IT" && Table1[Status]="Completed"))

VAR
ITProg = 
COUNTROWS(FILTER(Table1,Table1[Main Task]=EARLIER(Table1[Main Task]) && Table1[Category]="IT" && Table1[Status]="Progress"))

VAR
ITToDo = 
COUNTROWS(FILTER(Table1,Table1[Main Task]=EARLIER(Table1[Main Task]) && Table1[Category]="IT" && Table1[Status]="To Do"))

VAR
ITAll = 
COUNTROWS(FILTER(Table1,Table1[Main Task]=EARLIER(Table1[Main Task]) && Table1[Category]="IT"))

Return
IF(ITComp = ITAll,"Completed",IF(ITProg = ITAll,"Progress",IF(ITToDo = ITAll,"To Do","Progress")))

 

Anonymous
Not applicable

Hi chirayuw,

 

Perfectly working...Thanks Heaps...!

 

Best Regards,

Ganesh

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors