Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago

IN/OUT calcule

Hello,

I want to calculat the IN and OUT of my stock for 1 week.
I have already try that but it's more complicated than we think.

For exemple I have this table:

ArticleName articleWeek InWeek out
9BMotor2023-012023-03
9Dwheel2023-01 
9Gdrive shaft2023-012023-03
9RPinion2023-012023-01
9Ereserve2023-01 

 

In this case I want to count all OUT in 2023-03 week and all IN in 2023-03 week. After that I want to calcule CURRENT measure which equals the sum of all IN <= current week less than the sum of all OUT <= current week.
If we take the 2023-01 week we obtain: 5 IN & 1 OUT so CURRENT = 4.
I hope than someone can help me because I block on this problem and I don't find a solution.

Sincerly,
Imad RACHATI.

10 Replies

    • lbendlin's avatar
      lbendlin
      Super User

      would you mind providing the sample data for it here?

      • Imad-R's avatar
        Imad-R
        Frequent Visitor

        I want to send the files but I don't know how I can send it ?