Forum Discussion
line chart - display blank data
Good Afternoon,
I'm trying to create a line chart based of the below example data to plot tickets raised each day.
The issue I'm having is that when no tickets are raised on a particular date the value isn't set to 0.
How can i achieve this?
Hi Anonymous ,
Create a calendar table and create a relationship between the two tables based on date column.
Create measure like this:
Measure = IF(ISBLANK(SUM('Table'[Value])),0,SUM('Table'[Value]))Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
3 Replies
- MariuszCommunity Champion
Hi Anonymous
Add a date dimension/calendar table as below if you haven't.
https://radacad.com/create-a-date-dimension-in-power-bi-in-4-steps-step-1-calendar-columns
If you have a table with only closed records then create a measure like:
Measure = COUNTROWS( closedTable )if you have more statues in this table then:
Measure = COUNTROWS( CALCULATETABLE( Table, Table[status]= "Closed" ) )Best Regards,
Mariusz
If this post helps, then please consider Accepting it as the solution.
Please feel free to connect with me.
LinkedIn - amitchandakSuper User
Anonymous , Change the axis type to categorical. Another way put marker so that is known that data is not there on those days.
+0 in the calculation is a bad option to have, it will even remove date filter.
- V-lianl-msftCommunity Support
Hi Anonymous ,
Create a calendar table and create a relationship between the two tables based on date column.
Create measure like this:
Measure = IF(ISBLANK(SUM('Table'[Value])),0,SUM('Table'[Value]))Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.