Forum Discussion
Integer value column is summing up in line chart
Hi,
I have table in SQL with 3 columns Date,Table_name,no_of_records.For each date there will be 2 or 3 rows.When i'm trying to show this trend in power Bi i.e. no_of_records in y axis and date in x-axis using line chart the no_of_records is summing up for each date,but my requirement is not to summarize but to show each value of no_of_records on each day.Even I tried with other charts like bar chart,line and stacked column chart,clustered column chart etc but no luck.
could someone pls let me know how i can achieve not to summarize but to show each value of no_of_records on each day.
7 Replies
- v-qiuyu-msft
Community Support
Hi Anonymous,
In your scenario, as you put Date column in line chart X-axis and Date has many records on the same day, the line chart will show aggregated values based on X-axis group for each day.
To work around the issue, you can create a index column in Query Editor, then drag this index column to X-axis as well, then drill all levels to see desired values.
Reference:
https://docs.microsoft.com/en-us/power-bi/consumer/end-user-drill
Best Regards,
Qiuyun Yu- AnonymousNot applicable
Hi Qiuyun,
Thanks a lot for your response!! Actually i want to filter with Table_name, date(Audit_Capture_Date in my report) columns and see the trend in my report.Eg: for the date 12/1/2018 like the way u mentioned along with 3 entries for the tables a,b,c there can be one more record for table 'a' on the same date 12/1/2018.Can I use the index column in this case as well? My report looks something like below.
Also, i will use the index column in x-axis but don't want to display the index values 0,1,2 etc in the line chart.Is there any way to achieve this, pls let me know.
- v-qiuyu-msft
Community Support
Hi Anonymous,
As I mentioned previously, the line chart visual is used for display aggregated values instead of raw data.
In your scenario, if you would like to display three data points for the same X-axis value, the workaround is add another column in X-axis (eg: index column) to distinct records within the same date. The index column is not able to hide after putting this column in x-axis.
Best Regards,
Qiuyun Yu