SAP ISM_SE_MV45A_INIT_DISCOUNT Function Module for IS-M: Initialize Discount
ISM_SE_MV45A_INIT_DISCOUNT is a standard ism se mv45a init discount SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for IS-M: Initialize Discount 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 ism se mv45a init discount FM, simply by entering the name ISM_SE_MV45A_INIT_DISCOUNT into the relevant SAP transaction such as SE37 or SE38.
Function Group: JKSESAPMV45A05
Program Name: SAPLJKSESAPMV45A05
Main Program: SAPLJKSESAPMV45A05
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function ISM_SE_MV45A_INIT_DISCOUNT 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 'ISM_SE_MV45A_INIT_DISCOUNT'"IS-M: Initialize Discount.
EXPORTING
IN_VBELN = "Sales Document
* IN_SHOW_DATA = "Character Field of Length 1
IN_POSNR = "Sales document item
IN_ISMNOCONITEM = "IS-M: No Contract Item
IN_AUART = "Sales Document Type
IN_PSTYV = "Sales document item category
IN_KUNNR = "Sold-to Party
IN_PRODUCT = "Material Number
IN_ISMCONTRACT = "IS-M: Corresponding Contract
* IN_TRTYP = "Transaction Type
IMPORTING
OUT_USED = "
IMPORTING Parameters details for ISM_SE_MV45A_INIT_DISCOUNT
IN_VBELN - Sales Document
Data type: VBAK-VBELNOptional: No
Call by Reference: Yes
IN_SHOW_DATA - Character Field of Length 1
Data type: CHAR01Optional: Yes
Call by Reference: Yes
IN_POSNR - Sales document item
Data type: VBAP-POSNROptional: No
Call by Reference: Yes
IN_ISMNOCONITEM - IS-M: No Contract Item
Data type: VBAP-ISMNOCONITEMOptional: No
Call by Reference: Yes
IN_AUART - Sales Document Type
Data type: VBAK-AUARTOptional: No
Call by Reference: Yes
IN_PSTYV - Sales document item category
Data type: PSTYVOptional: No
Call by Reference: Yes
IN_KUNNR - Sold-to Party
Data type: KUNAGOptional: No
Call by Reference: Yes
IN_PRODUCT - Material Number
Data type: MARA-MATNROptional: No
Call by Reference: Yes
IN_ISMCONTRACT - IS-M: Corresponding Contract
Data type: VBAP-ISMCONTRACTOptional: No
Call by Reference: Yes
IN_TRTYP - Transaction Type
Data type: T180-TRTYPOptional: Yes
Call by Reference: Yes
EXPORTING Parameters details for ISM_SE_MV45A_INIT_DISCOUNT
OUT_USED -
Data type: CHAR01Optional: No
Call by Reference: Yes
Copy and paste ABAP code example for ISM_SE_MV45A_INIT_DISCOUNT 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_in_vbeln | TYPE VBAK-VBELN, " | |||
| lv_out_used | TYPE CHAR01, " | |||
| lv_in_show_data | TYPE CHAR01, " | |||
| lv_in_posnr | TYPE VBAP-POSNR, " | |||
| lv_in_ismnoconitem | TYPE VBAP-ISMNOCONITEM, " | |||
| lv_in_auart | TYPE VBAK-AUART, " | |||
| lv_in_pstyv | TYPE PSTYV, " | |||
| lv_in_kunnr | TYPE KUNAG, " | |||
| lv_in_product | TYPE MARA-MATNR, " | |||
| lv_in_ismcontract | TYPE VBAP-ISMCONTRACT, " | |||
| lv_in_trtyp | TYPE T180-TRTYP. " |
|   CALL FUNCTION 'ISM_SE_MV45A_INIT_DISCOUNT' "IS-M: Initialize Discount |
| EXPORTING | ||
| IN_VBELN | = lv_in_vbeln | |
| IN_SHOW_DATA | = lv_in_show_data | |
| IN_POSNR | = lv_in_posnr | |
| IN_ISMNOCONITEM | = lv_in_ismnoconitem | |
| IN_AUART | = lv_in_auart | |
| IN_PSTYV | = lv_in_pstyv | |
| IN_KUNNR | = lv_in_kunnr | |
| IN_PRODUCT | = lv_in_product | |
| IN_ISMCONTRACT | = lv_in_ismcontract | |
| IN_TRTYP | = lv_in_trtyp | |
| IMPORTING | ||
| OUT_USED | = lv_out_used | |
| . " ISM_SE_MV45A_INIT_DISCOUNT | ||
ABAP code using 7.40 inline data declarations to call FM ISM_SE_MV45A_INIT_DISCOUNT
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.| "SELECT single VBELN FROM VBAK INTO @DATA(ld_in_vbeln). | ||||
| "SELECT single POSNR FROM VBAP INTO @DATA(ld_in_posnr). | ||||
| "SELECT single ISMNOCONITEM FROM VBAP INTO @DATA(ld_in_ismnoconitem). | ||||
| "SELECT single AUART FROM VBAK INTO @DATA(ld_in_auart). | ||||
| "SELECT single MATNR FROM MARA INTO @DATA(ld_in_product). | ||||
| "SELECT single ISMCONTRACT FROM VBAP INTO @DATA(ld_in_ismcontract). | ||||
| "SELECT single TRTYP FROM T180 INTO @DATA(ld_in_trtyp). | ||||
Search for further information about these or an SAP related objects