turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Navigation
- Tecnomatix
- Forums
- Blogs
- Knowledge Bases
- Groups

- Siemens PLM Community
- Tecnomatix
- Plant Simulation
- Find the minimum out of a subset of a table

Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

03-28-2018 06:01 AM

Hi everyone!

I want to find the minimum value out of a table, but only for a specific subset of goods.

E.g. I have a Table with parts of the types A, B and C and a Timestamp when it was storaged. Now I want to retrieve an item of type A, which has been the longest in the storage.

How do I do that the most efficient way?

Greetings, Patrick

Solved! Go to Solution.

3 REPLIES

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

03-28-2018 06:47 AM

Regards

Always consider using the AttributeExplorer!

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

03-28-2018 10:16 AM

Hello Patrick,

for your application with a store and under consideration of accessability you could use the following method with your table file

TableFile.sort(3,"down") --Sorts the column with availability (1/0) of your MUs, here it is column number 3 TableFile.findFloor({3,*},0)--After sorting the first unaccessable row is found TableFile.min({2,1}..{2,TableFile.CursorY-1})--Find the MU that is accessable and entered earlier than all the others (here in column 2) print TableFile[TableFile.CursorX,TableFile.CursorY]--returns the entry time of that MU print TableFile.CursorY-- returns row number of MU

Kind regards,

Igor

------------------------------------------------------------------------------------------------------

Did you like the answer? Then click the Thumbs Up button.

Did the answer solve your problem? Then accept the answer as solution

Igor

------------------------------------------------------------------------------------------------------

Did you like the answer? Then click the Thumbs Up button.

Did the answer solve your problem? Then accept the answer as solution

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

03-29-2018 02:37 AM

Thanks for both your answers!

The solution of Igor seems like a good workaround and works for my model.

Maybe I will look further into the attribute explorer, but at the moment I don't exactly know how to use it and can't find a proper tutorial, so while it might be a good solution in the long run my current knowledge limits it's applicability.

Follow Siemens PLM Software

© 2018 Siemens Product Lifecycle Management Software Inc