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
Anonymous
Not applicable

comparative measure for calculated column

Good evening Teachers

Again I come to you for help, the following happens: I need to create a calculated column that groups information from computer models,
where if the count of the model is for example equal to or less than 10 units then you put "others", if this condition is not fulfilled then it returns the model of the computer.
In Excel I found it easy to solve with the following syntax:
= IF (COUNT.IF ([Model]; [@ Model]) <= 10; "others"; [@ Model])
but in dax I have not got it
I appreciate any guidance you can give me
1 ACCEPTED SOLUTION

Hi,

 

Try this calculated column formula

 

=if(CALCULATE(COUNTROWS(Table1),FILTER(Table1,[Modelo]=EARLIER([Modelo])))<10,"Others",[Modelo])

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

9 REPLIES 9
Anonymous
Not applicable

@v-shex-msft

@Ashish_Mathur

 

Thank you very much for your help teachers, again attach the link with edit permissions.
Any help will be appreciated.

 

Data Information

 

https://idearco-my.sharepoint.com/personal/smartraining_idearco_onmicrosoft_com/_layouts/15/guestacc...

 

 

 

Hi,

 

Try this calculated column formula

 

=if(CALCULATE(COUNTROWS(Table1),FILTER(Table1,[Modelo]=EARLIER([Modelo])))<10,"Others",[Modelo])

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
Anonymous
Not applicable

@Ashish_Mathur

@v-shex-msft

Thank you very much for the response so agile, I really do not know how to attach the file by this very place, so attach the link to download the .xls file

Even I have not managed to apply dax correctly in this type of cases, so what I have to do is to lower in excel and do it in the classic way.
Any help is appreciated
** question: can be obtained with the use of variables "VAR"

HI @Anonymous,

 

You can upload to onedrive or google drive and share the link here.

 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

Hi,

 

There is no download option available there.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
v-shex-msft
Community Support
Community Support

HI @Anonymous,

 

Please provide the sample data for further analysis.

 

BTW, you formula seems like to use count function and if statement to check the count of model column, right?

 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.
Anonymous
Not applicable

DataModel.jpg

Thank you very much for the answer so diligent, attached screenshots of how the information is, what I want is a column like "ModeloAgrupado", but in dax

 

Hi,

 

Why dont you share your file???  Anyways, try this calculated column formula

 

=IF(COUNTROW(FILTER(Data,Data[Modelo]=EARLIER(Data[Modelo])))<=10,"Otros",[Modelo])

 

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
Ashish_Mathur
Super User
Super User

Hi,

 

Show some data and the expected result.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Helpful resources

Announcements
Europe Fabric Conference

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.

Top Solution Authors