Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago
Solved

Logistics Forecast Distribution

Hi everyone!

Im trying to forcasting how our trucks are going to be busy in the next day.

The information that I have is the shipping plant (have many), the order and the stimating time of start time of the travel and when is going to finish.

I dont know yet which truck im gonna use for each order until next day, but I need to forecast a day before to see if im not over scheduling.

 

PlantOrderStart TimeFinish Time
51010096:29:00 a. m.8:24:00 a. m.
51011926:35:00 a. m.8:28:00 a. m.
51011926:50:00 a. m.8:43:00 a. m.
51010237:09:00 a. m.8:21:00 a. m.
51010097:29:00 a. m.9:24:00 a. m.
51010237:44:00 a. m.8:56:00 a. m.
51010917:50:00 a. m.9:33:00 a. m.
51010238:19:00 a. m.9:31:00 a. m.
51010098:29:00 a. m.10:24:00 a. m.
51013058:29:00 a. m.9:54:00 a. m.
51013228:29:00 a. m.9:54:00 a. m.
51010918:50:00 a. m.10:33:00 a. m.
51010238:54:00 a. m.10:06:00 a. m.
51013608:55:00 a. m.10:40:00 a. m.

 

This is what i have when the trucks are assigned, so im expecting something similar but with the estimation. (is a custom timeline visual, but if you have a better visual is welcome too):

 

What i was thinking is that depending on the start time, write something like a generate series from 1 to X (the numer of truck available), but if i made that measure it just drop me an error:

 

"A table of multiple values was supplied where a single value was expected."

 

Any sugestions?

 

  • lbendlin's avatar
    lbendlin
    3 years ago

    Let's assume you have index numbers in a column called [IDX] from 1 to n.  Your DAX would be something like

     

    Val = 1+MOD([IDX]-1,6)

     

     

4 Replies

  • you can use table variables in your measure but the final result of the measure must be a scalar value (a table with a single row and a single column).

     

    What should the measure compute?

    • Anonymous's avatar
      Anonymous
      Not applicable

      Im expecting to get another column with the numer I set in the what if parameter, get to that number and repeat based on the start time... i mean if I set de number 6, i would get the next information:

      1

      2

      3

      4

      5

      6

      1

      2

      3

      4

      5

      6

      1

      ...

      • lbendlin's avatar
        lbendlin
        Icon for Super User rankSuper User

        Let's assume you have index numbers in a column called [IDX] from 1 to n.  Your DAX would be something like

         

        Val = 1+MOD([IDX]-1,6)