question

Meng,Li avatar image
0 Likes"
Meng,Li asked Joerg Vogel commented

Is Table.addIndex() suitable for this situation?

1646820778777.png

Here is a table i built for managing storage, the values in column "current_quantity" change along the model running. Then i'm wondering is Table.addIndex() preferable in this situation?(eg. add index for column "part_no")

1646820747030.png

FlexSim 22.0.1
global table
1646820747030.png (113.9 KiB)
1646820778777.png (35.0 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

·
Joerg Vogel avatar image
0 Likes"
Joerg Vogel answered Joerg Vogel commented

As you quoted from manual, it is not intended for this kind of use. If you do it on another more static case like slots, then you could benefit from an index.

· 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.

Jason Lightfoot avatar image Jason Lightfoot ♦ commented ·
Also - consider using a list with fields instead - then you can more easily listen to events and select quantities that match requirements.
2 Likes 2 ·
Meng,Li avatar image Meng,Li Jason Lightfoot ♦ commented ·
Thanks for your suggestion, i will give it a shot.
0 Likes 0 ·
Meng,Li avatar image Meng,Li commented ·
OK, i get it.
0 Likes 0 ·
Joerg Vogel avatar image Joerg Vogel commented ·
Another more static value would be SKU values. If you look up for a value like a SKU and another field contains available amount of items and their location as string or pointer in arrays, an index can speed up your search. Important would be to keep even SKU values in your table, if there aren’t any items associated with. If your SKU pattern involves already directly a table row number you need not anymore an index.
0 Likes 0 ·

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.