Getting Production Order previous status
I know that we can use FM STATUS_TEXT_EDIT to get the current status of a Production Order. I'm wondering if we could also get the previous status of a Production Order? If we can, what is the steps or FM to use?
Gautham Yemmanuru replied
Usually statuses are fetched from JEST table.
But using the same OBJNR whcih we pass to the FM 'STATUS_TEXT_EDIT',
we can access the table JCDS, to get the previous statuses.
Just write SELECT OBJNR STAT UDATE UTIME
where OBJNR = OBJNR.
UDATE is the creation date of the change document, i.e the previous staus.
If you get more than one statuses for one OBJNR, You can sort the results by UDATE descending UTIME descending.
Then you will get the immediately previous status for this.
Hope this should resolve the issue.
Thanks & regards,