Forum Discussion
Sparkline in Table Visual
Hi,
I am trying to build the table below in Power BI but having issue to show the sparkline for different items and x-axis for 5 quarters(based on the selected quarter slicer).
I have tried to used an independent date table and calculation group, but still unable show the sparkline.
Attached the sample.pbix , please enlighten me on this.
9 Replies
- NaveenGandhiMemorable Member
Hi changhong
Please provide access to the PBIX so that i can have a look.
Thanks,
NG - changhongFrequent Visitor
Hi NaveenGandhi ,
I have provided the access.
Attached the same file in dropbox sample.pbix
Regards,
CH
- AnonymousNot applicable
Hi changhong ,
According to your description, you can't create a sparkline based on a quarter. you can refer to the following documentation to learn how to create a sparkline in power bi. please note the limitations of these operations.
Sparkline in Power BI - RADACAD
Create sparklines in a table or matrix in a report (preview) - Power BI | Microsoft Learn
Solved: Sparkline Visual - Microsoft Fabric CommunityBest regards,
Albert HeIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly
- changhongFrequent Visitor
Hi Anonymous ,
From the first link you provided, below is the statement from the article
"If you have a custom Date table created by Power Query or DAX or any other way, you can use fields such as Year-Month combination, or Year-Quarter combination, or just Year to have fewer data points in the sparkline."Best regards,
CH
- Ashish_MathurSuper User
Hi,
The problem is not 'building the sparkline" - that is a simple line chart. Perhaps the challenge is going back 4 quarters from the choen quarter. I have solved a similar question in the attached files. Please study my solution there and adapt it to your data.
Hope this helps.
- changhongFrequent Visitor
Hi Ashish_Mathur ,
In the sample pbix file provided, I had the similar implementation but it couldnt work in the table with multiple row items that get populated with switch statement.
Here is my calculation group "Prev 5 Quarters".
It works with line chart.
But it does not works with the table visual.
Best regards,
Chang Hong
- Ashish_MathurSuper User
As you can see in my file, it works fine even if you switch to a Table visual. Please review my solution again.