Visual Matrix: Mask blanks with " - " or anyother but should not enter in the calculation

Hello Community,

I have a request from my users to not show blanks on a Matrix base on time as shown in the picture:

Did try to mask with IF conditions ISBLANK but did remove the Matris out-of-date context.

My support question is if anyone has a solution to mask the Blank cells is no data to any other character. One of the reasons is also if there are Blank intervals the matrix table excludes the months with GAP.

Warm Regards, and thank you!
Jose Milhazes

Hi Jose
You could try the Format function. Build your measure something like this

YourFormattedMeasure =
IF(ISBLANK([YourMeasure],
" - “,
FORMAT([YourMeasure],”$###,###")
)

You’ll then need to sort the left/right alignment out in the matrix formatting.
If you need any conditional formatting you’ll need to refer to [YourMeasure] rather than [YourFormattedMeasure].

If you just want a zero in the box then try
IF(ISBLANK([YourMeasure],
0,
[YourMeasure])

Cheers
Pete

Cheers
Pete

2 Likes

Hi @BINavPete,

Hope you are well, thank you so much for your support! I did try that before, but that measure takes the matrix out of context, meaning that the date slicer dates between stop filtering the Matrix.

Warm Regards
Jose Milhazes

Try to wrap the measure in a CALCULATE function with ALLSELECTED dates

Something Like:
CALCULATE(
IF(ISBLANK([YourMeasure],
" - “,
FORMAT([YourMeasure],”$###,###")
),
ALLSELECTED([Date])
)

Where [Date] is your date from the calendar table

Pete

1 Like

Hi @BINavPete,

Thank you, did try that solution before and did not work! It’s realy strange why the mesure get out of the filter criteria :frowning:

Best Regards
Jose Milhazes

Hi,

Can you share your pbix so we can look where exactly the problem lies.

Thanks,
Anurag

1 Like

Hi @Anurag @BINavPete ,

Sorry for the time taken, I cannot share the original .pbix, add to create a dummy!
Please find the sample dataset with the report and the data file:


example.pbix (141.1 KB)
Example v1.xlsx (12.5 KB)

Warm Regards
Jose Milhazes

Hi,

If this is what you are looking for:
image

Attaching pbix for your reffrence:
example.pbix (140.8 KB)

2 Likes

Hi @Anurag ,

Thank you for your support. I already rested your solution and did not work. I’m using the visual Matrix has you using in your example. The issue is that as we MASK the empty date contact gets lost.
image
example V2.pbix (148.2 KB)

In attach you can find the .pbxi, I just enlarge the dates set to add 2020.

Best Regards
Jose Milhazes

Hi,

What actually we are aiming here to achieve.

Thanks,
Anurag

Hi,

The above problem arise because your data model does not contains a date table .(you forget to mark your date table as date table )
Now its showing the expected result:
image

Attaching pbix for your refrence:
example V2.pbix (142.1 KB)

You can visit the below link for creating your date table:

Thanks,
Anurag

1 Like

Indeed the Date table was not marked as a Date table. Thank you @Anurag