Starting December 3, join live sessions with database experts and the Microsoft product team to learn just how easy it is to get started
Learn moreGet certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now
Hi,
I would like to show the top 3 company tickers based on 'Weight, %' column.
I would also like this calculation to be responsive to a 'report view' filter, when filtering by year (i.e. top 3 companies in year 2022 will be different than in 2021, etc.)
Here is the full data set if needed:
https://docs.google.com/spreadsheets/d/1Sa9xva8HVuW7178WPJPV-nv0ClrqMwDM19SokaIztMM/edit#gid=0
Many thanks in advance
Hi,
I don't know how you want to model your data, but I assume your datamodel looks something like below.
I saw that there are two companies who has two Ticker categories. Please correct me if I misunderstood.
Top3 weight percent measure: =
CALCULATE (
DIVIDE ( SUM ( Data[Shares] ), SUM ( Data[Value] ) ),
KEEPFILTERS (
WINDOW (
1,
ABS,
3,
ABS,
ALLSELECTED ( Ticker[Ticker] ),
ORDERBY (
CALCULATE ( DIVIDE ( SUM ( Data[Shares] ), SUM ( Data[Value] ) ) ), DESC
)
)
)
)
If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.
Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.
User | Count |
---|---|
87 | |
83 | |
82 | |
65 | |
49 |
User | Count |
---|---|
135 | |
111 | |
100 | |
65 | |
62 |