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
Tim_Walker
Regular Visitor

Value of New Sales this year

Hi, I want to find the value of sales to new clients this year.  My table is Client Name, Invoice Date and Amount and the dates are spread over 2 fiscal years.  I simply need a measure (not a standalone table with filters) that I can add to a table showing the value of clients billed in Year 2 but not in year 1, but most importantly provides a total that I can use.  I have produced a number of measures which appear to give me the list, but none are able to produce a total.  Any help much appreciated...

1 ACCEPTED SOLUTION
v-yulgu-msft
Employee
Employee

Hi @Tim_Walker,

 

Sum sales =
IF (
    CALCULATE (
        COUNTROWS ( data ),
        FILTER (
            ALLEXCEPT ( data, data[Client Name] ),
            data[Invoice Date].[Year] < YEAR ( TODAY () )
        )
    )
        < 1,
    CALCULATE ( SUM ( data[Amount] ), ALLEXCEPT ( data, data[Client Name] ) ),
    BLANK ()
)

Best regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-yulgu-msft
Employee
Employee

Hi @Tim_Walker,

 

Sum sales =
IF (
    CALCULATE (
        COUNTROWS ( data ),
        FILTER (
            ALLEXCEPT ( data, data[Client Name] ),
            data[Invoice Date].[Year] < YEAR ( TODAY () )
        )
    )
        < 1,
    CALCULATE ( SUM ( data[Amount] ), ALLEXCEPT ( data, data[Client Name] ) ),
    BLANK ()
)

Best regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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.