Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
colourfullife
Post Partisan
Post Partisan

Don't want to cound blank value

Hi, 

 

i have this code

 

CSU SP_Constractual final =
VAR _End = CALCULATE ( MAX ( 'Data - CSU SP PO'[CONTRACTUAL_DELIVERY_DATE] ), ALL ( 'calendar' ))
RETURN
    IF (
        _End < MIN ( 'calendar'[Date] ),
        BLANK (),
CALCULATE(
    Sum('Data - CSU SP PO'[PO_LINE_QUANTITY]), USERELATIONSHIP('Data - CSU SP PO'[CONTRACTUAL_DELIVERY_DATE],'calendar'[Date]),
    FILTER(
        ALLSELECTED('calendar'[Date]),
        ('calendar'[Date] <= MAX('calendar'[Date])))))
 
can you tell me this code counts blank as value?
if so can you let me know how not to?
 
pic.PNG
4 REPLIES 4
Icey
Community Support
Community Support

Hi @colourfullife ,

 

Try to filter the x axis column as "is not blank" in "Filters in this visual" field.

 

 

Best Regards,

Icey

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

amitchandak
Super User
Super User

@colourfullife , You are doing some. So the count of blank Does not arise.

You are seeing blank because there are dates missing in the date of the calendar but those are available in CONTRACTUAL_DELIVERY_DATE

 

Check out for the missing dates and try to add them to the calendar . This the case when the axis it the date column from the calendar table

Hi@amitchandak 

 

You are right. that is the reason. Is there any way sum up the values if there are dates?

I just don't want to show blank values in my graph.

 

thanks,

CL

@colourfullife What is generating that 434 number at the bottom of your graph? Might have to share sample data.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.