Forum Discussion
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.
| Plant | Order | Start Time | Finish Time |
| 510 | 1009 | 6:29:00 a. m. | 8:24:00 a. m. |
| 510 | 1192 | 6:35:00 a. m. | 8:28:00 a. m. |
| 510 | 1192 | 6:50:00 a. m. | 8:43:00 a. m. |
| 510 | 1023 | 7:09:00 a. m. | 8:21:00 a. m. |
| 510 | 1009 | 7:29:00 a. m. | 9:24:00 a. m. |
| 510 | 1023 | 7:44:00 a. m. | 8:56:00 a. m. |
| 510 | 1091 | 7:50:00 a. m. | 9:33:00 a. m. |
| 510 | 1023 | 8:19:00 a. m. | 9:31:00 a. m. |
| 510 | 1009 | 8:29:00 a. m. | 10:24:00 a. m. |
| 510 | 1305 | 8:29:00 a. m. | 9:54:00 a. m. |
| 510 | 1322 | 8:29:00 a. m. | 9:54:00 a. m. |
| 510 | 1091 | 8:50:00 a. m. | 10:33:00 a. m. |
| 510 | 1023 | 8:54:00 a. m. | 10:06:00 a. m. |
| 510 | 1360 | 8: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?
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
- lbendlin
Super User
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?
- AnonymousNot 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
Super 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)