# Maintenance Orders Waiting for Material with Purchase Tracking Report

> A custom ALV report that shows, for every component of open maintenance orders, stock status, purchase requisition, purchase order, vendor and delivery date on the same line, and flags orders whose material is complete as ready. Planners see which job waits for which part without opening each order.

- Type: Report, Custom development, ALV report
- Module: PM
- Estimated effort: M (4–6 working days)
- Last updated: 2026-11-17
- URL: https://nekuhub.com/en/reports/maintenance-orders-waiting-for-material-report/


## Why is the standard not enough?

The IW38 order list has no columns for component material status, purchase requisition or purchase order; planners open every order in IW33, go from the component screen to the requisition and from there to ME5A and ME23N. The material availability check covers stock items only and does not show the purchasing stage of non-stock items and services. When the weekly schedule is prepared, jobs whose material has arrived are picked out by hand.

### Closest standard alternatives

- IW38: Lists maintenance orders; no columns for requisition, purchase order and delivery date per component.
- ME5A: Lists purchase requisitions; it does not show which maintenance job waits for the requisition or the order's start date.

## Tables used

| Table | Role | Access | Join | System |
|---|---|---|---|---|
| RESB | Order components, item category, open quantity and purchase requisition (driving table) | Read | - | ECC + S/4 |
| AFIH | Planning plant, planner group and equipment | Read | AFIH-AUFNR = RESB-AUFNR | ECC + S/4 |
| AUFK | Order type and short text | Read | AUFK-AUFNR = RESB-AUFNR | ECC + S/4 |
| AFKO | Basic start date | Read | AFKO-AUFNR = RESB-AUFNR | ECC + S/4 |
| MARD | Unrestricted stock of stock items | Read | MARD-MATNR = RESB-MATNR AND MARD-WERKS = RESB-WERKS AND MARD-LGORT = RESB-LGORT | ECC + S/4 |
| EBAN | Purchase requisition, release status and assigned order | Read | EBAN-BANFN = RESB-BANFN AND EBAN-BNFPO = RESB-BNFPO | ECC + S/4 |
| EKET | Delivery date and received quantity | Read | EKET-EBELN = EBAN-EBELN AND EKET-EBELP = EBAN-EBELP | ECC + S/4 |
| EKKO | Vendor of the purchase order | Read | EKKO-EBELN = EBAN-EBELN | ECC + S/4 |
| LFA1 | Vendor name | Read | LFA1-LIFNR = EKKO-LIFNR | ECC + S/4 |
| MAKT | Material description of stock items | Read | MAKT-MATNR = RESB-MATNR AND MAKT-SPRAS = SY-LANGU | ECC + S/4 |

## Selection screen parameters

| Parameter | Description | Type | Reference field | Required |
|---|---|---|---|---|
| S_IWERK | Maintenance planning plant | Range / multiple | AFIH-IWERK | Yes |
| S_AUFNR | Maintenance order | Range / multiple | RESB-AUFNR | No |
| S_INGPR | Planner group | Range / multiple | AFIH-INGPR | No |
| S_AUART | Order type | Range / multiple | AUFK-AUART | No |
| S_GSTRP | Basic start date | Range / multiple | AFKO-GSTRP | No |
| S_MATNR | Material | Range / multiple | RESB-MATNR | No |
| P_KEYDT | Key date (default: today) | Single value | SY-DATUM | Yes |
| P_NOTRDY | Orders with incomplete material only | Checkbox | - | No |

## Output columns

| Column | Source |
|---|---|
| Maintenance order | RESB-AUFNR |
| Short text | AUFK-KTEXT |
| Equipment | AFIH-EQUNR |
| Basic start | AFKO-GSTRP |
| Material | RESB-MATNR |
| Material / service text | Calculated: MAKT-MAKTX for stock items, EBAN-TXZ01 for non-stock items |
| Item category | RESB-POSTP |
| Open qty | Calculated: RESB-BDMNG − RESB-ENMNG |
| Unit | RESB-MEINS |
| Purchase requisition | RESB-BANFN |
| Purchase order | EBAN-EBELN |
| Vendor | LFA1-NAME1 |
| Delivery date | EKET-EINDT |
| Material status | Calculated: In stock, requisition awaiting release, requisition released, on order or received |
| Delay against start (days) | Calculated: EKET-EINDT − AFKO-GSTRP (positive: the job cannot start) |

## How does the report work?

1. Open maintenance orders (AUTYP = 30; not TECO or CLSD) are read from AUFK and AFIH, the basic start (GSTRP) from AFKO. Components are taken from RESB (XLOEK blank, KZEAR blank); open quantity = BDMNG − ENMNG.
2. Stock item (POSTP = L): compared with unrestricted stock MARD-LABST at the component's plant and storage location; when enough, the status is in stock. When not enough and RESB-BANFN is filled, the requisition is followed.
3. Non-stock item (POSTP = N) or item with a requisition: requisition (BANFN/BNFPO), release indicator (FRGKZ), deletion (LOEKZ) and assigned purchase order (EBELN/EBELP) are read from EBAN. Delivery date (EINDT) and received quantity (WEMNG) come from EKET; the vendor name is added through EKKO-LIFNR → LFA1-NAME1.
4. Material status: in stock / requisition awaiting release / requisition released, no PO / on order / received, awaiting issue.
5. Delay against start = EKET-EINDT − AFKO-GSTRP; a positive value means the order cannot start on the planned date. When all lines of an order are in stock or received, the order is flagged as ready.
6. ALV groups by planner group and order; ready orders are shown in green.

## Authorization objects

- I_IWERK: Display orders by maintenance planning plant
- M_BANF_WRK: Display purchase requisitions by plant
- M_BEST_WRK: Display purchase orders by plant

## Frequently asked questions

### Are service items tracked as well?

Yes. Non-stock items and external services are followed through the purchase requisition on RESB. The service entry sheet status can be added as an optional column.

### What if stock is already reserved for other orders?

By default, unrestricted stock is shared between orders in the order of their requirement dates, so two jobs that need the same spare part do not count the same stock twice.

### Does it work on S/4HANA?

Yes. RESB, AFIH, EBAN and EKET keep the same structure in S/4HANA; reading MARD is served from material documents through a compatibility view.

---
Let us build this report for your system: https://nekuhub.com/en/request-a-quote/?report=pm-orders-waiting-for-material
