question

Kari Payton avatar image
0 Likes"
Kari Payton asked Jason Lightfoot commented

Is there a way to query a list of task executors by closest distance to puller?

querylist.fsmI had a list of 72 operators avaivable on a list and 8 different fixed resources that pull the operators they need from the list for different sub processes. In real life the operators closest to the fixed resource will work in that location. Is there a way to use the query list option for this?

FlexSim 17.0.1
query
querylist.fsm (34.2 KiB)
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

1 Answer

·
anthony.johnson avatar image
1 Like"
anthony.johnson answered Jason Lightfoot commented

You should be able to just pull from the list with the query: ORDER BY distance, as distance is one of the fields you get with a task executer list. You may need to adjust the distance field's code if you have some weird scenario, but in general it should just work.

· 4
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Kari Payton avatar image Kari Payton commented ·

Hi @anthony.johnson I created a model example. I am getting an error on the distance field code. querylist.fsm

0 Likes 0 ·
querylist.fsm (34.2 KiB)
Jeff Nordgren avatar image Jeff Nordgren commented ·

@anthony.johnson,

In her model when I look at the entries in the List, under the column header "distance", it just says "Puller Required". Should that be a number of some kind? Is that why there are a bunch of errors when the pull is ORDER BY distance ASC?

0 Likes 0 ·
Jon Abbott avatar image Jon Abbott Jeff Nordgren commented ·

Hi @anthony.johnson and @Jeff Nordgren, I am encountering the same issue in FlexSim 2020 - pulling by distance doesn't seem to work, and all of the list entries just say "Puller required" even after an item has been pulled. I changed the puller to refer to the token label that refers to the other object, and have also tried setting it to leave items on the list, but nothing seems to work. Is there an example model somewhere for this that I can refer to?

0 Likes 0 ·
Jason Lightfoot avatar image Jason Lightfoot ♦ Jon Abbott commented ·

When you open the list entries look over at the quick properties where you can define the puller using the sample or typing an expression. Selecting your puller will let you see if the "puller required" is replaced with the correct distance expression.

1 Like 1 ·
1607043768486.png (2.0 KiB)

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.