Forum Discussion
Anonymous
5 years agoNot applicable
New Column to Check if Duplicate, Add Marking
Hi there,
Im trying to build a column to check duplication of invoice invoice number. The result can be as follows:
I tried the posting here, https://community.powerbi.com/t5/Desktop/Add-column-where-the-first-duplicate-value-gets-value-1-and-the/m-p/900836 , but it doesnt work.
Thank you.
Anonymous
pls try this
Column =VAR _count=CALCULATE(COUNTROWS('Table'),FILTER('Table','Table'[Index]<EARLIER('Table'[Index])&&'Table'[Invoice No]=EARLIER('Table'[Invoice No])))return if(ISBLANK(_count),'Table'[Invoice No],'Table'[Invoice No]&"-"&_count)
3 Replies
- ryan_mayuSuper User
Anonymous
pls try this
Column =VAR _count=CALCULATE(COUNTROWS('Table'),FILTER('Table','Table'[Index]<EARLIER('Table'[Index])&&'Table'[Invoice No]=EARLIER('Table'[Invoice No])))return if(ISBLANK(_count),'Table'[Invoice No],'Table'[Invoice No]&"-"&_count)- AnonymousNot applicable
Works like a charm! Thank you!
- ryan_mayuSuper User
you are welcome