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

Use always the last month values to use in another measure

Hello everyone I need somebody´s help.
I want to have a measure that always sum the last month from today month costs and use those values in another measure. But the important thing is that it has to be always the last month sum of costs without using filters or slicers. This is because i want to use them in another measure "inventory value/(always last month costs/365)". 

Thank you very much

1 ACCEPTED SOLUTION

@davidibarrag 

 

You may take a look at the links below.

Community Support Team _ Sam Zha
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

3 REPLIES 3
kentyler
Solution Sage
Solution Sage

you might check out the PREVIOUSMONTH() function

PREVIOUSMONTH

  1.  

Returns a table that contains a column of all dates from the previous month, based on the first date in the dates column, in the current context.

Syntax

DAXCopy
PREVIOUSMONTH(<dates>)  

Parameters

   
TermDefinition
DatesA column containing dates.

Return value

A table containing a single column of date values.

Remarks

This function returns all dates from the previous month, using the first date in the column used as input. For example, if the first date in the dates argument refers to June 10, 2009, this function returns all dates for the month of May, 2009.

The dates argument can be any of the following:

  • A reference to a date/time column.

  • A table expression that returns a single column of date/time values.

  • A Boolean expression that defines a single-column table of date/time values.

and use it to get the dates to sum up in a measure...which you could then refer to in another measure





Did this post answer your question? Mark it as a solution so others can find it!

Help when you know. Ask when you don't!




Join the conversation at We Talk BI find out more about me at Slow BI


What im looking for is a measure that always always take the las month costs. For example, if today is September, then i want that my measure always take the sum of costs from august. This is because in the other measure i need only the last month costos. Pregunta.png

@davidibarrag 

 

You may take a look at the links below.

Community Support Team _ Sam Zha
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.