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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
Anonymous
Not applicable

Inventory Value end month per Warehouse

Hi 
I want to have the Inventory value per end of each month per warehouse and per Materialcode.
This is an example of the data i have:

wsharifzada_0-1666603605539.png

Thank you in advance!

 

6 REPLIES 6
Anonymous
Not applicable

Hi @Anonymous 

Did you get the result you want ? If the above replies are helpful to you , please consider Accept it as the solution to help the other members find it more quickly .

 

Best Regards,
Community Support Team _ Ailsa Tao

Anonymous
Not applicable

Hi Ailsa Tao,

It did not worked yet. 

Kind regards.

 

Walid

Waldo35
Helper I
Helper I

I am gonna assume you don't need a running total here because the value is new inventory. 

 

Here is my dataset

Waldo35_0-1666605959803.png

I generated roughly 7 months. And here are the steps i take, please note if u use a calendar table you should do that in there, not in the table itself.

 

1. In power query i extract the year and month from the date field, I do this by duplicating the date field and extracting the year. In a calendar table you would use MONTH and YEAR to extract these. But in this example i will use Power Query. I made 2 duplicates (right click date column and duplicate, then in transform, choose date, year, year) (Do the same to the other column but go for Month).

Schermafbeelding 2022-10-24 120928.png

 

Now apply the changes and go back to the report editor.

 

2. Right click year and Create Hierarchy. After that add the month field to the hierarchy, rightclick add to hierarchy

Schermafbeelding 2022-10-24 121122.png

 

3. Add the year and month to a table with as seperate columns from the hierarchy and then add the value field, you now have a total for the value per month. 

 

Now the splitting into category part

I added a column category to my dataset. Which contains either 1 or 2.

Schermafbeelding 2022-10-24 121721.png

 

Now all i have to do is just throw the category in there. And there view of Year and Month, categorized:

Schermafbeelding 2022-10-24 121850.png

 

 

 

 

Anonymous
Not applicable

Hi Waldo,
Thank you for your effort!
I have already the stock value per date. The specific value of the last date of the month is the value for the end of the  month. 
Kind regards. 

Walid

Jihwan_Kim
Super User
Super User

Hi,

I am not sure whether I understood your question correctly, but I tried to create a sample pbix file like below.

Please check if it is suitable for your datamodel.

 

Jihwan_Kim_1-1666606665981.png

 

 

Jihwan_Kim_0-1666606646003.png

 

 

 

last nonblankdate: =
VAR _lastdate =
    LASTNONBLANK ( 'Calendar'[Date], CALCULATE ( SUM ( Data[New Inventory] ) ) )
VAR _lastinventory =
    CALCULATE ( SUM ( Data[New Inventory] ), 'Calendar'[Date] = _lastdate )
RETURN
    _lastinventory


Microsoft MVP



If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.




LinkedInVisit my LinkedIn page




Outlook BookingSchedule a short Teams meeting to discuss your question



Anonymous
Not applicable

 

Hi Jihwan Kim
Thank you for your effort!
My data contains inventory value per date. For example :
In Warehouse " NLMA3.0-2" on 03-10-2022  6 pieces in stock
In Warehouse "NLMA3.0-2" on 11-10-2022  5 pieces in stock
In Warehouse "NLMA3.0-2" on 18-10-2022  4 pieces in stock
De last value  in Oktober for this article is 18-10-2022. So the value should be: 4 pieces on end of Oktober. Now it gives the som of these three value moments.

Kind regards. 

Walid
 

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

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