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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
red_arrowhead
Helper I
Helper I

How to create a sum measure with specific conditions

I have data divided into calander weeks. I have a few identifiers and their values divided into columns of calender weeks which are  created from dates and relationships with calender weeks. 

Now I want to have a visual with can showthe sum of first 5 identifiers together into all calender weeks and another row with sum of last 2 identifiers together into all calender weeks. 

How can I do it?

Example 

red_arrowhead_0-1612344947707.png

Here I want sum of all values of A,B,C,D together in those seperate CW

and sum of E,F into another row seperated into CW

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@red_arrowhead , Not very clear. You have to create a new column like this and use that

 


Switch(True(),
[identifier] in {"A","B","C", "D"} , "Cat1",
[identifier] in {"E", "F"},"Cat2"
)

View solution in original post

1 REPLY 1
amitchandak
Super User
Super User

@red_arrowhead , Not very clear. You have to create a new column like this and use that

 


Switch(True(),
[identifier] in {"A","B","C", "D"} , "Cat1",
[identifier] in {"E", "F"},"Cat2"
)

Helpful resources

Announcements
Fabcon_Europe_Social_Bogo

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

Check out the June 2024 Power BI update to learn about new features.

PBI_Carousel_NL_June

Fabric Community Update - June 2024

Get the latest Fabric updates from Build 2024, key Skills Challenge voucher deadlines, top blogs, forum posts, and product ideas.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.