Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreWe've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now
Hi Everyone,
Requesting you post the solutin or any advice for the below question.
TABLE1
| EMP ID | SALARY | SAVINGS | EXPENSES | TAX PAID |
| 1 | 10000 | 1000 | 9000 | 500 |
| 2 | 5000 | 1500 | 3500 | 600 |
| 3 | 15000 | 5000 | 10000 | 700 |
| 4 | 8000 | 2400 | 5400 | 350 |
| 5 | 9000 | 3200 | 5700 | 550 |
| 6 | 7500 | 800 | 6700 | 700 |
| 7 | 6000 | 500 | 5500 | 800 |
Slicer 1
| Metric (Drop down Silcer) |
| SALARY |
| SAVINGS |
| EXPENSES |
| TAX PAID |
Slicer 2
| Sort (Radio Button Slicer) |
| ASC |
| DSC |
Above is the TABLE1 consists of Columns SALARY, SAVINGS, EXPENSES, TAXPAID and there need two slicers like as above Slicer 1 and Slicer .
Now the requirement is if i select one Metric from Metric Slicer Ex. SAVINGS and selected ASC then the SAVINGS Column in the table should sort in Ascending order and if select DSC then it should sort in the Descending Order in the Same table without any Bookmarks.
Finally based on the Selection of Metric in Metric Slicer and Selection of Sort Slicer the Metric Value in the Table should Sort Accordingly.
Help me out with closest solution.
Thanks in Advance.
Regards,
Pentakoa
Solved! Go to Solution.
Hi @Anonymous ,
You can try this measure
SORT =
SWITCH (
SELECTEDVALUE ( 'Slicer 2'[Sort] ),
"ASC",
SWITCH (
SELECTEDVALUE ( 'Slicer 1'[Metric] ),
"EXPENSES", SUMX ( 'TABLE1', [EXPENSESASC] ),
"SALARY", SUMX ( 'TABLE1', [SALARYASC] ),
"SAVINGS", SUMX ( 'TABLE1', [SAVINGSASC] ),
"TAX PAID", SUMX ( 'TABLE1', [TAX PAIDASC] )
),
"DSC",
SWITCH (
SELECTEDVALUE ( 'Slicer 1'[Metric] ),
"EXPENSES", SUMX ( 'TABLE1', [EXPENSESDESC] ),
"SALARY", SUMX ( 'TABLE1', [SALARYDESC] ),
"SAVINGS", SUMX ( 'TABLE1', [SAVINGSDESC] ),
"TAX PAID", SUMX ( 'TABLE1', [TAX PAIDDESC] )
)
)
You can check more details from here.
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous ,
You can try this measure
SORT =
SWITCH (
SELECTEDVALUE ( 'Slicer 2'[Sort] ),
"ASC",
SWITCH (
SELECTEDVALUE ( 'Slicer 1'[Metric] ),
"EXPENSES", SUMX ( 'TABLE1', [EXPENSESASC] ),
"SALARY", SUMX ( 'TABLE1', [SALARYASC] ),
"SAVINGS", SUMX ( 'TABLE1', [SAVINGSASC] ),
"TAX PAID", SUMX ( 'TABLE1', [TAX PAIDASC] )
),
"DSC",
SWITCH (
SELECTEDVALUE ( 'Slicer 1'[Metric] ),
"EXPENSES", SUMX ( 'TABLE1', [EXPENSESDESC] ),
"SALARY", SUMX ( 'TABLE1', [SALARYDESC] ),
"SAVINGS", SUMX ( 'TABLE1', [SAVINGSDESC] ),
"TAX PAID", SUMX ( 'TABLE1', [TAX PAIDDESC] )
)
)
You can check more details from here.
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @amitchandak Is there any solution for the same without using any Bookmarks?
No. It should be only in a slicer
Hi, I found this solutions is something close . Can you please look into it and help me.
https://community.powerbi.com/t5/Desktop/Sort-order-with-multiple-columns-of-slicer/m-p/611430
https://community.powerbi.com/t5/Desktop/Sort-order-with-multiple-columns-of-slicer/m-p/611430
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 51 | |
| 37 | |
| 35 | |
| 19 | |
| 17 |
| User | Count |
|---|---|
| 70 | |
| 64 | |
| 39 | |
| 33 | |
| 23 |