Christa Posted June 27, 2019 Posted June 27, 2019 In the batch that was created, I want to search the member entity with the lowest value for state variable "NumberOfRollContainers" and change its value to: <<TotalREQ" - 0.9 * "CapacityTrip">>, where "TotalREQ" and "CapacityTrip" are state variables of the parent entity. I am struggling with how to use the search step in this situation, so help is appreciated. Thanks in advance!
gocken Posted June 27, 2019 Posted June 27, 2019 After being sure that you have at least one member entity (you can check this by using a decide step or an auxiliary expression within the search step). Then, set search steps match condition property as "Math.Min(xxx.NumberOfRollContainers)". And, place an assign step at "found" branch of search step. At this step you can change its value.
jzhou Posted June 27, 2019 Posted June 27, 2019 1 hour ago, Christa said: In the batch that was created, I want to search the member entity with the lowest value for state variable "NumberOfRollContainers" and change its value to: <<TotalREQ" - 0.9 * "CapacityTrip">>, where "TotalREQ" and "CapacityTrip" are state variables of the parent entity. I am struggling with how to use the search step in this situation, so help is appreciated. Thanks in advance! Kindly check the attached model for how to search the lowest value , kindly note the lowest value maybe more than 1, so I first search out the lowest value and check again if there is many copies of the lowest value..... all the best! →→→→❤ Model_totalRollContainer_JZ(2).spfx 1
Recommended Posts