I have a toughie, I think.
I have one query, where I grab a manufacturing order, its steps (10, 20, 30) and it’s work area (PA2, PA3, PA4). However, in my query, I specify which work area through a condition.
Results are a single row within a manufacturing order
MO | MO step | Work Area
2000 | 40 | PA4
2001 | 30 | PA4
2002 | 30 | PA4
This works fine.
Now, I want to show Work area where the last completed MO Step was in a new column beside the work area. I make another query that grabs MO, MO Step, Work Area, Step Completed (yes/no).
In order to do this, I have to first grab all the completed steps within the MO (through a sub-query: Object: MO Step Condition: MO Step Complete = Yes), then within all the completed MO steps dataset, I have to grab the MAX MO step. Then I will link the 2 queries based on MO and put in the last work area complete.
The problem is that I am finding is that I can’t put a calculation on my sub-query.
Is there a way to do this?
dusted (BOB member since 2003-09-18)