Enterprise Resource Planning Blogs by SAP
Get insights and updates about cloud ERP and RISE with SAP, SAP S/4HANA and SAP S/4HANA Cloud, and more enterprise management capabilities with SAP blog posts.
Showing results for 
Search instead for 
Did you mean: 
Product and Topic Expert
Product and Topic Expert

Recently you may notice a problem that the GR material document is cancelled, but the corresponding inspection lot is not cancelled together with the material document. You can still see the inspection lot in t-code MD04.

Here is basically what happened:


  • The indicator "Manual sample calc." is set for the inspection type 01/04 in MM03 or no inspection plan or material specification is created for the material although the inspection type requires one.
  • No early lot creation in case of origin 04, which means the field "Control insLot" is not set to "Y Early lot creation for the order item" for the affected inspection type.

    It looks something like below in MM03:


  1. Post goods receipt to a order in t-code MB31 or MIGO.
  2. An inspection lot is created with status CRTD.
  3. Check MMBE. QI stock increased.
  4. Cancel the GR material document which created the inspection lot in MBST.


  1. QA03 : Inspection lot is not cancelled. The status is still CRTD.
  2. MMBE: QI stock disappeared.
  3. MD04: Inspection lot is still displayed.

Permanent fix:

Implement SAP Note 2186161. This note fixes a bug in this case. After applying this note, when you post new GR material document cancellations in MBST, the inspection lot will be cancelled together with it. Lot status becomes LTCA automatically and won't be displayed in MD04.

Inconsistency correction:

For existing inspection lots, to correct the inconsistency, follow the steps below:

  1. Execute the report ZQEVAC20 in note 48815 for the material and plant.

    After this report is executed, the inspection lot status should become SPCO.

    The inspection lot is no longer displayed in MD04:
  2. If you are still concerned about the lot status CRTD and want to change it to LTCA, you may firstly assign an inspection plan and calculate the sample size of the inspection in QA02. Then the lot status would become REL. Then you can go to QA11 to record a dummy usage decision so that lot status becomes UD.

    At last cancel the inspection lot in QA12.

  3. If you are unable to carry out step 2 because you cannot assign an inspection plan to the inspection lot, report an incident to SAP Product Support under component QM-IM for further help.