SAP SPP01_SALESORDER_GETSTATUS Function Module for Sales Order:Get Status









SPP01_SALESORDER_GETSTATUS is a standard spp01 salesorder getstatus SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Sales Order:Get Status processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.


See here to view full function module documentation and code listing for spp01 salesorder getstatus FM, simply by entering the name SPP01_SALESORDER_GETSTATUS into the relevant SAP transaction such as SE37 or SE38.

Function Group: SPP01
Program Name: SAPLSPP01
Main Program: SAPLSPP01
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Remote-Enabled
Update:



Function SPP01_SALESORDER_GETSTATUS pattern details

In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.
CALL FUNCTION 'SPP01_SALESORDER_GETSTATUS'"Sales Order:Get Status
EXPORTING
IF_SALESDOCUMENT = "Sales and Distribution Document Number
* IF_GET_TEXTS = 'X' "Single-character flag

IMPORTING
ES_RETURN = "Return message
EF_PO_NUMBER = "Customer purchase order number
EF_DOC_DATE = "Document date (date received/sent)
EF_REQUESTED_DATE = "Requested delivery date
EF_ORDER_VALUE = "Net value of the order in document currency
EF_ORD_REASON = "Order reason (reason for the business transaction)
EF_ORDER_TYPE = "Sales document type

TABLES
* ET_STATUSINFO = "Status information
* ET_STATUSINFO_TEXTS = "Table of SCRTEXT
* ET_MATERIAL_SERIAL_NUMBERS = "Material Serial Numbers
.



IMPORTING Parameters details for SPP01_SALESORDER_GETSTATUS

IF_SALESDOCUMENT - Sales and Distribution Document Number

Data type: CHAR10
Optional: No
Call by Reference: No ( called with pass by value option)

IF_GET_TEXTS - Single-character flag

Data type: CHAR1
Default: 'X'
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXPORTING Parameters details for SPP01_SALESORDER_GETSTATUS

ES_RETURN - Return message

Data type: BAPIRET2
Optional: No
Call by Reference: No ( called with pass by value option)

EF_PO_NUMBER - Customer purchase order number

Data type: BSTNK
Optional: No
Call by Reference: No ( called with pass by value option)

EF_DOC_DATE - Document date (date received/sent)

Data type: AUDAT
Optional: No
Call by Reference: No ( called with pass by value option)

EF_REQUESTED_DATE - Requested delivery date

Data type: EDATU_VBAK
Optional: No
Call by Reference: No ( called with pass by value option)

EF_ORDER_VALUE - Net value of the order in document currency

Data type: NETWR_AP
Optional: No
Call by Reference: No ( called with pass by value option)

EF_ORD_REASON - Order reason (reason for the business transaction)

Data type: AUGRU
Optional: No
Call by Reference: No ( called with pass by value option)

EF_ORDER_TYPE - Sales document type

Data type: AUART
Optional: No
Call by Reference: No ( called with pass by value option)

TABLES Parameters details for SPP01_SALESORDER_GETSTATUS

ET_STATUSINFO - Status information

Data type: SPPORDSTAT1
Optional: Yes
Call by Reference: Yes

ET_STATUSINFO_TEXTS - Table of SCRTEXT

Data type: SPPSCRTEXT
Optional: Yes
Call by Reference: Yes

ET_MATERIAL_SERIAL_NUMBERS - Material Serial Numbers

Data type: MATERIAL_SERIAL_NUM
Optional: Yes
Call by Reference: Yes

Copy and paste ABAP code example for SPP01_SALESORDER_GETSTATUS Function Module

The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the newer method of declaring data variables on the fly. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8), which i why i have stuck to the origianl for this example.

DATA:
lv_es_return  TYPE BAPIRET2, "   
lt_et_statusinfo  TYPE STANDARD TABLE OF SPPORDSTAT1, "   
lv_if_salesdocument  TYPE CHAR10, "   
lv_ef_po_number  TYPE BSTNK, "   
lv_if_get_texts  TYPE CHAR1, "   'X'
lt_et_statusinfo_texts  TYPE STANDARD TABLE OF SPPSCRTEXT, "   
lv_ef_doc_date  TYPE AUDAT, "   
lt_et_material_serial_numbers  TYPE STANDARD TABLE OF MATERIAL_SERIAL_NUM, "   
lv_ef_requested_date  TYPE EDATU_VBAK, "   
lv_ef_order_value  TYPE NETWR_AP, "   
lv_ef_ord_reason  TYPE AUGRU, "   
lv_ef_order_type  TYPE AUART. "   

  CALL FUNCTION 'SPP01_SALESORDER_GETSTATUS'  "Sales Order:Get Status
    EXPORTING
         IF_SALESDOCUMENT = lv_if_salesdocument
         IF_GET_TEXTS = lv_if_get_texts
    IMPORTING
         ES_RETURN = lv_es_return
         EF_PO_NUMBER = lv_ef_po_number
         EF_DOC_DATE = lv_ef_doc_date
         EF_REQUESTED_DATE = lv_ef_requested_date
         EF_ORDER_VALUE = lv_ef_order_value
         EF_ORD_REASON = lv_ef_ord_reason
         EF_ORDER_TYPE = lv_ef_order_type
    TABLES
         ET_STATUSINFO = lt_et_statusinfo
         ET_STATUSINFO_TEXTS = lt_et_statusinfo_texts
         ET_MATERIAL_SERIAL_NUMBERS = lt_et_material_serial_numbers
. " SPP01_SALESORDER_GETSTATUS




ABAP code using 7.40 inline data declarations to call FM SPP01_SALESORDER_GETSTATUS

The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.

 
 
 
 
DATA(ld_if_get_texts) = 'X'.
 
 
 
 
 
 
 
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!