Forum Discussion
create sorted table and keep duplicates
- 5 years ago
thanks to all who tried to help me out with this but actually it worked for me using the following measures
Hierarchy Title =VAR CurrentHierarchy = SELECTEDVALUE(fTransactions[EmpID])RETURNMINX(FILTER(ALLSELECTED(fTransactions),fTransactions[EmpID]=CurrentHierarchy),RELATED(dHierarchy[Hierarchy title]))Main Degree Title =VAR CurrentMainDegree = SELECTEDVALUE(fTransactions[EmpID])RETURNMINX(FILTER(ALLSELECTED(fTransactions),fTransactions[EmpID]=CurrentMainDegree),RELATED(dMainDegree[Degree]))Sub Degree Title =VAR CurrentSubDegree = SELECTEDVALUE(fTransactions[EmpID])RETURNMINX(FILTER(ALLSELECTED(fTransactions),fTransactions[EmpID]=CurrentSubDegree),RELATED(dSubDegrees[Sub Degree]))
ah ok that's a good idea I'll try this and let you know the results
Hi Islam ,
Create a measure as below:
_index = IF(MAX('Table'[Index])=CALCULATE(MAX('Table'[Index]),FILTER(ALL('Table'),'Table'[EmpID]=MAX('Table'[EmpID]))),1,BLANK())
Then put the measure in the filter pane,choose "is not blank":
And you will see:
For the related .pbix file,pls see attached.
Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!
- Islam5 years agoHelper V
thanks for your help sir but it gave me an empty values like following picture
- Islam5 years agoHelper V
i'm getting crazy brother i tested your measure and it gives a perfect answers for your model but for mine it gives me both two SubDegreeID like this image
- v-kelly-msft5 years agoCommunity Support
Hi Islam ,
Dont worry,you should use "ALL" instead of "VALUES"."VALUES" is not suitable here.
Best Regards,
KellyDid I answer your question? Mark my post as a solution!