How-toSAP ECC / S/4HANAMM / FI GR/IR Clearing

SAP GR/IR clearing account balance: reconcile with MB5S and clear with MR11

Question
SAP GR/IR clearing account balance not zero, how to clear with MR11 and MB5S

Also searched as

  • SAP GR/IR reconciliation MB5S
  • SAP MR11 GR/IR account maintenance
  • SAP GR/IR open items old goods receipts F.13

Short answer

The GR/IR clearing account holds the value of goods received but not yet invoiced, and invoices not yet matched with receipts. It should trend to zero per PO item. Reconcile it with MB5S, find the PO items that are stuck, and clear true differences with MR11 or automatic clearing in F.13, after correcting the cause.

Applies to: SAP ECC 6.0 and S/4HANA, MM with automatic account determination (transaction key WRX)

Reconcile and clear the GR/IR account

  1. 1Run MB5S (Balance Display GR/IR) for the company code and key date. It compares the GR/IR account balance with the PO history and lists the difference.
  2. 2Run FBL3N on the GR/IR account (transaction key WRX in OBYC) to see open items. Items are posted by goods receipt (credit) and invoice (debit); each pair should offset per PO item.
  3. 3Use ME2N or ME80FN with the GR/IR selection, or EKBE, to find PO items where goods receipts exceed invoices or the reverse. Investigate each aged item.
  4. 4Resolve the cause first: post the missing invoice in MIRO, post a delayed goods receipt in MIGO, set the delivery completed indicator, or reverse a wrong movement.
  5. 5For small, genuine differences left over, run MR11 (GR/IR Clearing Account Maintenance) in test mode. It writes off the difference to price difference or an expense account.
  6. 6Run F.13 (automatic clearing) on the GR/IR account so that matched items clear in the ledger. The clearing links to the assignment field, which is set to PO number and item.
  7. 7Use F.19 (GR/IR clearing analysis) at period end if you need to regroup GR/IR balances for reporting, with the balance sheet adjustment documented.

What posts to GR/IR

A goods receipt against a PO debits stock (or consumption) and credits the GR/IR clearing account at PO price. The invoice receipt in MIRO debits GR/IR and credits the vendor. If quantities and prices match, the net per PO item is zero. Any difference is either a timing difference, which resolves itself, or a data problem that does not.

Price differences between the PO and invoice post to the price difference account (PRD) or into the stock for moving average price materials, so they do not remain on GR/IR. Quantity differences do remain, which is why GR/IR build-up is mostly a quantity story.

The PO history in table EKBE carries each movement with a process indicator in VGABE: 1 for goods receipt, 2 for invoice receipt. Comparing the sums of these per item is the basis for any reconciliation query.

-- Quantity received vs invoiced per PO item
SELECT EBELN, EBELP,
  SUM(CASE WHEN VGABE = '1' THEN MENGE ELSE 0 END) AS gr_qty,
  SUM(CASE WHEN VGABE = '2' THEN MENGE ELSE 0 END) AS ir_qty
FROM EKBE WHERE BEWTP IN ('E','Q')
GROUP BY EBELN, EBELP
HAVING SUM(CASE WHEN VGABE = '1' THEN MENGE ELSE 0 END)
    <> SUM(CASE WHEN VGABE = '2' THEN MENGE ELSE 0 END);

Typical causes of stuck balances

Goods received but never invoiced: services or freight not billed, free-of-charge deliveries, or vendors who invoice in batches. Invoiced but never received: pre-payments or invoices posted against the wrong PO item, and goods that arrived but were not booked in MIGO.

Another group is posting errors that were reversed on one side only, or invoices posted at a different price with the wrong tax code. The delivery completed indicator (EKPO-ELIKZ) and final invoice indicator (EREKZ) also affect MR11 and F.19. Items marked complete are treated differently when you clear.

Do not use MR11 as a default fix. It writes off the value, and writes off hide process problems such as receiving without a PO or invoicing the wrong item.

MR11 versus F.13 versus F.19

MR11 clears the differences on the GR/IR account for PO items in a way that removes the open balance by posting a correcting entry to another account. It is a business write-off and needs accounting approval. F.13 is automatic clearing in the ledger, which matches already offsetting items so the account shows only true open items. It writes no value.

F.19 is a period end analysis and regrouping report used to show GR/IR balances as receivables or payables on the balance sheet, with separate lines for goods received not invoiced. It is a reporting aid, not a correction.

Controls to keep it small

Review GR/IR monthly by age bucket, with the oldest items first. Assign an owner per plant. Set a business rule for write-off thresholds and delegate small values to MR11 runs with reviewed variants. Agree with receiving that all deliveries are booked on the day they arrive.

Common pitfalls

  • !Running MR11 in update mode without a test run and without accounting sign-off.
  • !Clearing the ledger account with F.13 and believing the underlying PO item mismatch is solved.
  • !Ignoring service entry sheets (ML81N), which post to GR/IR like goods receipts and are easy to leave unapproved.
  • !Reconciling only by value and not by quantity, which hides offsetting errors.
  • !Setting the delivery completed flag on items to make them disappear from reports while goods are still due.

How an ERP-grounded AI assistant handles this

A grounded assistant can run the reconciliation logic across EKBE and the GR/IR ledger items, rank the aged PO items by value, and say for each whether goods or invoice is missing. ERPray shows the query so a finance analyst can verify the numbers, and the output goes to a person for the write-off decision. It does not run MR11 on its own.

Frequently asked questions

What is the GR/IR clearing account in SAP?

It is a balance sheet account that holds goods received not yet invoiced. A goods receipt credits it and the invoice receipt debits it, per PO item. Its account is determined through the WRX transaction key in OBYC. A healthy balance is small and made up of recent items awaiting vendor invoices.

What does MB5S show?

MB5S compares the GR/IR account balance with the PO history for a key date and displays, per PO item, the goods received and invoiced values and quantities. It is the first reconciliation step because it tells you whether the account balance agrees with the purchasing documents.

Is MR11 safe to run?

Run it in test mode first and only with accounting approval. MR11 posts a correcting entry that writes off the open difference, so the account looks clean while the underlying issue remains if you have not found the cause. Use it for small, understood differences, not as routine cleanup.

Why does GR/IR not clear automatically with F.13?

F.13 clears only items that net to zero per assignment, usually the PO and item. If the received and invoiced quantities or values differ, the items stay open. Check the clearing criteria on the account, and fix the underlying receipt or invoice before running clearing again.

Related

How-to

SAP MIRO: invoice blocked for price variance, and how to release it in MRBR

MIRO blocks an invoice for payment when its price or quantity differs from the PO or goods receipt by more than the tolerance limits defined in OMR6. The invoice posts, but it carries a payment block reason (R for price) until someone releases it in MRBR or corrects the underlying data. Release only after confirming which side is wrong.

Error fix

SAP MIGO error M7 053: posting only possible in periods X and Y

M7 053 means the posting date of a goods movement is outside the two open material periods held in table MARV. Either use a posting date inside the allowed periods, or have inventory accounting open the right period with MMRV or advance it with MMPV. FI periods in OB52 are a separate check and can cause a different message.

How-to

SAP open purchase orders report: ME2N, ME2M, ME2L and the underlying tables

Use ME2N for a flexible open PO list, ME2M by material and ME2L by vendor, with the selection parameter Still to be delivered. The open quantity is the scheduled quantity in EKET minus goods received in EKBE, excluding deleted and delivery-completed items. For custom reports, read EKKO, EKPO, EKET and EKBE.

Error fix

SAP M7 021: Deficit of SL Stock Quantity

M7 021 fires during a goods issue, delivery, or confirmation when SAP checks the unrestricted-use (SL) stock for the exact plant, storage location and batch combination and finds less than what you are trying to post out. Fix the entry (batch, storage location, quantity) first; only enable negative stock or downgrade the message to a warning if the business genuinely needs to post ahead of a receipt.

Error fix

SAP IDoc Status 51: Application Document Not Posted

Status 51 tells you the IDoc reached the application layer and failed to post, but the status text itself is not the error - the real cause sits in the status record's long text or the linked application log. Fix the underlying data or configuration, then reprocess the IDoc through BD87 rather than editing the status.

Error fix

SAP Short Dump TIME_OUT: Maximum Runtime Exceeded

A TIME_OUT runtime error means a dialog (or RFC) work process ran longer than the maximum allowed runtime, controlled by profile parameter rdisp/max_wprun_time (600 seconds by default). The fix is almost always to move the long-running work to background processing or tune the underlying program, not to raise the timeout.

AI for ERP

AI for SAP S/4HANA, Running On-Prem or in Your Private Cloud

Run AI on SAP S/4HANA without sending ERP data to a public API. On-prem and private-cloud architecture, CDS views, OData, and honest deployment trade-offs.

AI for ERP

Get AI Value From SAP ECC Now, and Use It to De-Risk the Move to S/4HANA

SAP ECC 6.0 mainstream maintenance ends in 2027. Add AI value on ECC now, using its existing BAPIs and IDocs, and use it to de-risk the S/4HANA migration.

Stuck on SAP ECC / S/4HANA?

Talk to engineers who work inside SAP ECC / S/4HANA every week, and who build private AI that answers these questions from your own ERP data.