SAPFree generatorPDF, Excel, Word exportSAP S/4HANA

SAP Open Outbound Deliveries ABAP SELECT Generator (LIKP / LIPS)

Logistics coordinators regularly ask for a list of deliveries that are planned but not yet shipped. This generator produces an ABAP SELECT against the delivery header table LIKP and item table LIPS, filtered by plant, shipping point and planned goods issue date.

Fill in

Generated code
Download:

ABAP: open outbound deliveries (not yet goods issued)

REPORT zr_open_deliveries.

DATA: lv_plant  TYPE werks_d VALUE '1000',
      lv_vstel  TYPE vstel   VALUE '1000',
      lv_from   TYPE dats    VALUE '20261001',
      lv_to     TYPE dats    VALUE '20261031',
      lv_lfart  TYPE lfart   VALUE 'LF'.

SELECT likp~vbeln,
       likp~lfart,
       likp~vstel,
       likp~wadat,
       likp~kunnr,
       lips~posnr,
       lips~matnr,
       lips~lfimg,
       lips~vrkme,
       lips~werks
  FROM likp
  INNER JOIN lips ON lips~vbeln = likp~vbeln
  WHERE likp~lfart      = @lv_lfart
    AND likp~vstel      = @lv_vstel
    AND likp~wadat      BETWEEN @lv_from AND @lv_to
    AND likp~wadat_ist  = '00000000'
    AND lips~werks      = @lv_plant
  ORDER BY likp~wadat, likp~vbeln, lips~posnr
  INTO TABLE @DATA(lt_open)
  UP TO 5000 ROWS.

IF sy-subrc <> 0.
  WRITE: / 'No open deliveries found.'.
  RETURN.
ENDIF.

LOOP AT lt_open INTO DATA(ls_open).
  WRITE: / ls_open-vbeln, ls_open-posnr, ls_open-matnr, ls_open-lfimg, ls_open-vrkme, ls_open-wadat.
ENDLOOP.

Optional: goods movement status check

* In S/4HANA, goods movement status WBSTK is also on LIKP (A = not yet processed).
* To restrict to unprocessed deliveries add this to the WHERE clause:
*   AND likp~wbstk = 'A'
* On ECC systems the status lives in VBUK-WBSTK, so join VBUK on VBELN instead.

LIKP is the delivery header and LIPS the delivery item. WADAT is the planned goods movement date and WADAT_IST the actual goods movement date, which is initial until goods issue is posted. Test in a sandbox first, and verify field names in SE11 on your release. Add authority checks and a proper selection screen before using this as a production report.

Ask SAP delivery questions in plain English

Optional: see how a read-only natural language layer could answer open delivery questions from your SAP system.

Optional. The tool and every export work without this. No spam.

How to use the generator

Enter your plant, shipping point, delivery type and date range. The output updates with a complete report skeleton you can paste into SE38 or an ABAP development tool in Eclipse. Replace the WRITE statements with an ALV grid for real use. Because the SELECT uses the newer inline syntax with the @ escape, your system needs ABAP 7.40 or higher, which covers every S/4HANA release.

  • VSTEL is the shipping point on the header.
  • WERKS on the item is the delivery plant.
  • LFIMG is the actual quantity delivered in sales unit VRKME.

How the logic works

In SAP, an outbound delivery stays open until the goods issue is posted. At that point the actual goods movement date WADAT_IST on LIKP is filled. While it is still initial (00000000) the delivery has not left. Comparing the planned date WADAT with today surfaces late deliveries. Joining LIPS gives material, quantity and unit per line, which you can then enrich with MAKT for descriptions or KNA1 for customer names.

Common mistakes

Developers often forget the item plant filter, which duplicates rows for multi-plant deliveries, or compare dates as strings with the wrong format. Another mistake is relying on the old VBUK status table in S/4HANA, where the statuses moved to the delivery header. Finally, large date ranges without UP TO n ROWS or indexes on a big LIKP can slow down a production system, so test with representative volumes.

Frequently Asked Questions

Which SAP tables hold outbound deliveries?

LIKP holds the delivery header and LIPS the delivery items. Document flow is tracked in VBFA. In ECC the header status fields were in VBUK and item status in VBUP. In S/4HANA the status fields were moved into the delivery tables.

How do I know a delivery has been goods issued?

The actual goods movement date WADAT_IST on LIKP is filled when the goods issue is posted, and the goods movement status WBSTK becomes C. While the date is initial, the delivery is still open for picking, packing or posting.

Can I use this in older SAP releases?

The syntax needs ABAP 7.40 SP08 or higher. For older releases, rewrite the SELECT in the classic form with an explicit INTO TABLE and declared work area, remove the @ escapes, and use the VBUK table for status checks.

Does this generator change data in SAP?

No. The output is a read-only SELECT. Even so, test it in a non-production system, add authority checks as required by your company and avoid unrestricted selections on large tables.

If you want natural language access to open deliveries and shipping status without building each report, Netray's ERPray can answer these questions read-only on top of your SAP data.