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
restevez11
Frequent Visitor

Average with Datesbetween

Hi,
I have some unexpected values that I dont understand why they appear.

 

I calculate a daily value using average called D_1 Auction as below:

restevez11_0-1666712500614.png

 

I also calculated a monthly average using my Dates Table called Fechas, and related to the table "Mibgas PVB"). I call this measure 

restevez11_1-1666712611643.png

As expected, with a monthly context, both measures are equal, but in the second one, the total average appears without any date.

restevez11_2-1666712760729.png

 

 Why this value appears and how can I get rid off it?


Thanks

 

 

1 ACCEPTED SOLUTION
restevez11
Frequent Visitor

Solved using this measure:

D_1 Auction Promedio = IF( [D_1 Auction]=BLANK(),BLANK(),
 CALCULATE(
    [D_1 Auction],
    DATESBETWEEN(Fechas[Dia],STARTOFMONTH(Fechas[Dia]),ENDOFMONTH(Fechas[Dia]))
)
)
 

View solution in original post

1 REPLY 1
restevez11
Frequent Visitor

Solved using this measure:

D_1 Auction Promedio = IF( [D_1 Auction]=BLANK(),BLANK(),
 CALCULATE(
    [D_1 Auction],
    DATESBETWEEN(Fechas[Dia],STARTOFMONTH(Fechas[Dia]),ENDOFMONTH(Fechas[Dia]))
)
)
 

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.