Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Dears,
I have created a Top N slicer, which shows me the chosen Top N of Expenses of Assets. I have created a new Table, parameter and a measure "Top N Asset) for the slicer: see below the measure:
Solved! Go to Solution.
Hi @Anonymous ,
If you want to use the parameter to interact with other visuals, you can create a calculate column for rank first:
Rank = RANKX('Basis','Basis'[Expenses USD])
Then create a control measure, set its value as 1 and put it in the filter of the visual like table:
Slicer control =
IF ( SELECTEDVALUE ( 'Basis'[Rank] ) <= [TOP N Value], 1, 0 )
The result may like this:
Here is the sample file that hopes to help you, please try it: PBIX
By the way, which confused me is that if you want to show the topn result in the visual, why not create a rank column like the previous mentioned and use it as a slicer directly instead of using what-if parameters to create topN manually.
Best Regards,
Yingjie Li
If this post helps then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous ,
If you want to copy some columns from one table, you can create a calculate table like this:
Copy table =
SUMMARIZE ( 'Table', 'Table'[column1], 'Table'[column2] )
Please refer: https://docs.microsoft.com/en-us/dax/summarize-function-dax
If not help, could you please consider provide a dummy .pbix or sample data for further discussion?
Best Regards,
Yingjie Li
If this post helps then please consider Accept it as the solution to help the other members find it more quickly.
Hi @v-yingjl
below you can see a smal version of my Datatable (Basis).
Country | Category | Asset Name | Expenses USD | FEE | Activation | Media |
Germany | Football | Accor Hotels Arena | 2000 | 2000 | 0 | 0 |
Belgium | Venue | Olympia | 3000 | 2000 | 1000 | 0 |
GB | Music | Zenith | 4000 | 1000 | 2000 | 1000 |
Germany | Football | Football cup | 5000 | 2500 | 2500 | 0 |
France | Venue | Federation Française de Football | 6000 | 2000 | 2000 | 2000 |
France | Music | Paris Saint-Germain | 7000 | 3000 | 2000 | 2000 |
France | Other | Paris Other | 8000 | 2000 | 4000 | 2000 |
The other Table is parameter (What if): Generateseries(0;20;1) + the measure from my first post.
I want a slicer that shows me the Top N of Assets. I got it, but the slicer or the Table dont interact with the other visuals. The others show always all Assets, not the TOP N.
Is that enough?
Thank you,
Albert
Hi @Anonymous ,
If you want to use the parameter to interact with other visuals, you can create a calculate column for rank first:
Rank = RANKX('Basis','Basis'[Expenses USD])
Then create a control measure, set its value as 1 and put it in the filter of the visual like table:
Slicer control =
IF ( SELECTEDVALUE ( 'Basis'[Rank] ) <= [TOP N Value], 1, 0 )
The result may like this:
Here is the sample file that hopes to help you, please try it: PBIX
By the way, which confused me is that if you want to show the topn result in the visual, why not create a rank column like the previous mentioned and use it as a slicer directly instead of using what-if parameters to create topN manually.
Best Regards,
Yingjie Li
If this post helps then please consider Accept it as the solution to help the other members find it more quickly.
Hi @v-yingjl ,
Thank you for your help.
I tried the first approach, but it does not work correctly with my Data. When I choose 0, it shows me 3. Maybe the 3 Assets are wrong data. I dont know, why it shows me 3. If I choose 1, it shows me 4. So I think it something with the data.
The second approach is much more easier and makes more sense and it works. Thank you.
If you have a tip why the first approach may not work, it would be great. I am just interested, why.
Thank you
Albert
Hi @v-yingjl,
I have already tried that. The problem is, that then the Parameter doesnt work.
I also tried with "addclolumn" in the parameter it doesnt work to, maybe I did it wrong.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
115 | |
99 | |
88 | |
70 | |
62 |
User | Count |
---|---|
151 | |
120 | |
103 | |
87 | |
68 |