Forum Discussion
Finding MAX in each category
- 6 years agoYou could try this as a calc column:
IsMax - IF( 'Table1'[Transaction] a MAXX(FILTER(ALL('Table1'), 'Table1'[Name] ? EARLIER('Table1'[Name])), 'Table1'[Transaction]), "Yes", "No")
All the solutions provided by AllisonKennedy mahoneypat Anonymous have actually worked.
Can I add one more similar question to it? This will remove the unnecessary tables and improve the data model.
Lets say I have just 1 field:
Field:
A01/01/2020
A01/01/2020
A01/01/2020
A03/12/2020
B02/11/2020
B03/29/2020
Is it possible to add a new calculated column which give the counts:
Example: records 1,2 and 3 will give 3 each because they belong to the same category (A01/01/2020) and then 4,5,6 gives 1 each.
HI kabra_ashish ,
Create a measure = CALCULATE(COUNTA(Table[id]) , FILTER(ALL(Table) , Table[id] = MAX(Table[id]))
Regards,
Harsh Nathani
Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)
- Anonymous6 years agoNot applicable
HI kabra_ashish ,
You can also create a colun
Column = COUNTX(FILTER('Table', 'Table'[Id] = EARLIER('Table'[Id])),'Table'[Id])\
Regards,
Harsh Nathani
Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)