Help writing SQL syntax

Help writing SQL syntax

willrs
Not applicable
266 Views
4 Replies
Message 1 of 5

Help writing SQL syntax

willrs
Not applicable

[ FlexSim 23.0.15 ]

In this model, trucks arrive and use docks for loading and unloading. At first, type 1 trucks arrive. However, when type 2 trucks arrive, they have priority for loading.

I tried to build SQL syntax by integrating WHERE with ORDER, but it didn't work.


1729287031227.png

problem-sql-syntax.fsm

0 Likes
Accepted solutions (1)
267 Views
4 Replies
Replies (4)
Message 2 of 5

moehlmann_fe
Advocate
Advocate
Accepted solution

Which token gets to acquire something first is controlled by the "Back Order Queue Strategy" you can set in the resource's properties.

It also takes the form of an SQL query ORDER BY clause where "puller" references the token. The following would allow tokens with a higher "Tipo" label to acquire a dock before others.

1729490555030.png

0 Likes
Message 3 of 5

willrs
Not applicable

Thanks Felix, this worked!

But I have a question about how to write an SQL syntax, using WHERE and ORDER, directly in "Acquire". Isn't that possible?

Thank you very much!

0 Likes
Message 4 of 5

Jeanette_Fullmer
Community Manager
Community Manager

Hello @WillRS,

The query on the acquire activity will be for the resources. The back-order strategy query will be for the tokens acquiring the resource. In the case that you want to order the tokens, you will apply a SQL query to the back orders like he described. You will find this in the advanced options for the resource.


1729538113039.png

0 Likes
Message 5 of 5

willrs
Not applicable

Okay, I understand

Thanks!

0 Likes