global table item creation

global table item creation

priyankasgoudar33
Enthusiast Enthusiast
1,148 Views
8 Replies
Message 1 of 9

global table item creation

priyankasgoudar33
Enthusiast
Enthusiast

[ FlexSim 20.0.10 ]

Hello I have a model where in source 1 I am creating two variant type parts. when part 1 that is var1 enters the processor. In both Queue2 and Queue3 part should be created following global table var1. and when var2 part enters in processor var2 global table should be followed to create item.

The item created in Queue should be pallet on part. for particular variant part particular item should be created.

variant.fsm


@Felix Möhlmann

0 Likes
Accepted solutions (1)
1,149 Views
8 Replies
Replies (8)
Message 2 of 9

FelixMoehlmann
Collaborator
Collaborator
Accepted solution

As the item names and table names are equal, you can use the name to directly reference the table from which the data should be taken.

'Table(token.item.name)[row][col]'

I'm not sure what exactly you by 'particular item' that should be created, so in the attached model I just set the names of the created objects to the text in the tables.

If you want to actually create different flow item types, I would suggest to type in the rank of the respective item in the flow item bin into the table. This can then be read by the 'Create Objects' activity.

1658403089631.png

variant_fm.fsm

0 Likes
Message 3 of 9

priyankasgoudar33
Enthusiast
Enthusiast

Hi @Felix Möhlmann

If I have 20 Queue in my Model and 20 items(same process as above). Each buffer should be assigned to one particular item(Ex: P1_var1/P1_var2 should be assigned to Queue2 same as P2_var1/P2_var2 to Queue3 and so on). How can I do it

variant-fm.fsm

0 Likes
Message 4 of 9

FelixMoehlmann
Collaborator
Collaborator

I'd add an extra column to the tables, storing the information which queue the items should be moved to.

1658473896291.png

In addition, you can use the process flow block that creates the items as a subflow. This subflow can then run as many times as there are rows in the table, automatically scaling with the table size.

1658473869822.png

variant-fm2.fsm

0 Likes
Message 5 of 9

priyankasgoudar33
Enthusiast
Enthusiast
@Felix Möhlmann is the table name related to code?
0 Likes
Message 6 of 9

FelixMoehlmann
Collaborator
Collaborator
Yes, like I mentioned in the original answer. The items' names are used to refer to the table with the same name. (Item name is 'var1' -> read data from table 'var1')
0 Likes
Message 7 of 9

priyankasgoudar33
Enthusiast
Enthusiast
@Felix Möhlmann how can I do the same model without process flow just with coding can you help with this.
0 Likes
Message 8 of 9

jason_lightfoot_adsk
Autodesk
Autodesk
You need a loop and the commands createcopy and either moveobject or assign the '.up' attribute of the thing you want to move to the destination container.

eg:

item.up=newcontainer;
0 Likes
Message 9 of 9

kavika_faleumu
Autodesk
Autodesk

Hi @mary, was Felix Möhlmann's answer helpful? If so, please click the "Accept" button at the bottom of their answer. Or if you still have questions, add a comment and we'll continue the conversation.

If we haven't heard back from you within 3 business days we'll auto-accept an answer, but you can always unaccept and comment back to reopen your question.

0 Likes