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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
skorpion
Helper I
Helper I

If Condition or other method to move other catagry

I have data which have 24 products but i need if any product in less thn 5% its will come as Other catagry for example

 

 

Iron = 10%

Clothes = 15%

Shoes = 4.99%

Shockes 3.9%

Pen = 46%

 

Output will like this 

 

Iron = 10%

Clothes =15%

Pen = 46%

other = 8.89%

6 REPLIES 6
skorpion
Helper I
Helper I

any one please

Hi scorpion,

 

To achieve your requirement, please create a calculated column like below: 

New Material = IF(Table1[Percentage] <= 0.05, "Other", Table1[Material])

 

Then you can drag the calculated column to a table visual, set it with SUM aggregation. For details, you can refer to PBIX file: https://www.dropbox.com/s/kak2ero9hniy4y1/Test.pbix?dl=0

Capture.PNG

 

Regards,

Jimmy Tao

i did my percentage via measure .. its not coming from main database 

Hi scorpion,

 

Based on your description, you mean [Percentage] is a measure, right?

 

It depends on which DAX used in the measure. Assume the [Percentage] do sum aggregation,

 

Percentage = SUMX(Sheet1, Sheet1[PercentageCol])

 

In this scenario, we can create a calculated column based on [Percentage] measure like below:

 

New Material = IF([Percentage] <= 0.05, "Other", Sheet1[Material])

 

The result is as below and you can refer to PBIX file: https://www.dropbox.com/s/kak2ero9hniy4y1/Test.pbix?dl=0

 1.PNG

 

If it doesn’t work, could you please share your PBIX file with me for further test?

 

Regards,

Jimmy Tao

still geeting error 

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.