Skip to Content

Setting sample status from QE51N instead of QPR2 Tcode


As we know, we can change sample status from QPR2 Tcode from Created->Received->Inprocess->Complete as seen below,

I have a custom report where i display completion date for sample by fetching E0004 status from JCDS table by passing OBJNR against sample(Fetch OBJNR against sample from QPRS table).

Users set completion date & time for a sample in QE51N Tcode as seen below,

This can be done by double clicking the sample(step 1). Then click the button as highlighted above(step 2) and in the appearing popup, inspection end date & time is displayed. Note that by completing the status from QE51N, E0004 status record does not generate in JCDS table which happens if we set status as COMP from QPR2 Tcode.

Is there a way we can set status of sample in QPR2 tcode whenever sample is completed from QE51N Tcode. I am an abaper & i have challenges to understand the mechanics of QM module. Please share your valuable inputs.



sample.png (44.8 kB)
sample1.png (95.3 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Sep 07, 2017 at 02:36 PM

    Sure. When does the sample status need to be updated? You can look to do this by any one of several user exits that get triggered when y ou save your results or make a UD. Please search for a list of QM user exits and look at the ones triggered when the results are saved or inspection lot saved. One of these could probably be tapped to run QPR2 and update the lot. You might have to do it on a delay such as a submitted batch job in order to make sure there are no systems locks on the sample by the inspection lot being exited.

    Add comment
    10|10000 characters needed characters exceeded