SAP ISH_GET_QUANTITY_SERVICES Function Module for IS-H: Determines the quantity of specific services
ISH_GET_QUANTITY_SERVICES is a standard ish get quantity services 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-H: Determines the quantity of specific services 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 ish get quantity services FM, simply by entering the name ISH_GET_QUANTITY_SERVICES into the relevant SAP transaction such as SE37 or SE38.
Function Group: N011
Program Name: SAPLN011
Main Program: SAPLN011
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function ISH_GET_QUANTITY_SERVICES 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 'ISH_GET_QUANTITY_SERVICES'"IS-H: Determines the quantity of specific services.
EXPORTING
* AUFDT = '19000101' "Date at which case admitted
* ETLZT = '240000' "Time at which case discharged
* FALNR = "Case Number
* NBGDT = '00000000' "Start date of a follow-up service
* NBGZT = '000000' "Start time of a follow-up service
* S_PARAM = '01' "Parameter which service should be billed
* TALST = ' ' "Charge master of performed service
* TARID = ' ' "ID of performed service
* AUFZT = '000000' "Time at which case admitted
BEGDT = "Date at which service begins
* BEGZT = '000000' "Time at which service begins
EINRI = "Institution
ENDDT = "Date at which service ends
* ENDZT = '240000' "Time at which service ends
* ETLART = ' ' "Discharge type of case
* ETLDT = '99991231' "Date at which case discharged
IMPORTING
QUANTITY = "Service Quantity
EXCEPTIONS
AUFDT_GT_BEGDT = 1 AUF_GT_ETL = 2 BEGDT_GT_ENDDT = 3 ETLDT_LT_ENDDT = 4 INVALID_EINRI = 5 INVALID_S_PARAM = 6
Customer Function user exits
Below is a list of CUSTOMER FUNCTION exit user exits that are available within this program and maybe relevant for this FM.EXIT_SAPLN011_001 IS-H: User Exit for Customer-Defined Valuation Formulas
IMPORTING Parameters details for ISH_GET_QUANTITY_SERVICES
AUFDT - Date at which case admitted
Data type: SY-DATUMDefault: '19000101'
Optional: Yes
Call by Reference: No ( called with pass by value option)
ETLZT - Time at which case discharged
Data type: SY-UZEITDefault: '240000'
Optional: Yes
Call by Reference: No ( called with pass by value option)
FALNR - Case Number
Data type: NFAL-FALNROptional: Yes
Call by Reference: No ( called with pass by value option)
NBGDT - Start date of a follow-up service
Data type: NLEI-NBGDTDefault: '00000000'
Optional: Yes
Call by Reference: No ( called with pass by value option)
NBGZT - Start time of a follow-up service
Data type: NLEI-NBGZTDefault: '000000'
Optional: Yes
Call by Reference: No ( called with pass by value option)
S_PARAM - Parameter which service should be billed
Data type: NTPK-BFORMDefault: '01'
Optional: Yes
Call by Reference: No ( called with pass by value option)
TALST - Charge master of performed service
Data type: NTPK-TALSTDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
TARID - ID of performed service
Data type: NTPK-TARIFDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
AUFZT - Time at which case admitted
Data type: SY-UZEITDefault: '000000'
Optional: Yes
Call by Reference: No ( called with pass by value option)
BEGDT - Date at which service begins
Data type: SY-DATUMOptional: No
Call by Reference: No ( called with pass by value option)
BEGZT - Time at which service begins
Data type: SY-UZEITDefault: '000000'
Optional: Yes
Call by Reference: No ( called with pass by value option)
EINRI - Institution
Data type: TN01-EINRIOptional: No
Call by Reference: No ( called with pass by value option)
ENDDT - Date at which service ends
Data type: SY-DATUMOptional: No
Call by Reference: No ( called with pass by value option)
ENDZT - Time at which service ends
Data type: SY-UZEITDefault: '240000'
Optional: Yes
Call by Reference: No ( called with pass by value option)
ETLART - Discharge type of case
Data type: NBEW-BWARTDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
ETLDT - Date at which case discharged
Data type: SY-DATUMDefault: '99991231'
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for ISH_GET_QUANTITY_SERVICES
QUANTITY - Service Quantity
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
AUFDT_GT_BEGDT - Admission date > start of service
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
AUF_GT_ETL - Admission of case after discharge
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
BEGDT_GT_ENDDT -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
ETLDT_LT_ENDDT - Discharge date < end of service
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
INVALID_EINRI - Wrong institution
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
INVALID_S_PARAM - Wrong parameter specified
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for ISH_GET_QUANTITY_SERVICES 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_aufdt | TYPE SY-DATUM, " '19000101' | |||
| lv_quantity | TYPE SY, " | |||
| lv_aufdt_gt_begdt | TYPE SY, " | |||
| lv_etlzt | TYPE SY-UZEIT, " '240000' | |||
| lv_falnr | TYPE NFAL-FALNR, " | |||
| lv_nbgdt | TYPE NLEI-NBGDT, " '00000000' | |||
| lv_nbgzt | TYPE NLEI-NBGZT, " '000000' | |||
| lv_s_param | TYPE NTPK-BFORM, " '01' | |||
| lv_talst | TYPE NTPK-TALST, " SPACE | |||
| lv_tarid | TYPE NTPK-TARIF, " SPACE | |||
| lv_aufzt | TYPE SY-UZEIT, " '000000' | |||
| lv_auf_gt_etl | TYPE SY, " | |||
| lv_begdt | TYPE SY-DATUM, " | |||
| lv_begdt_gt_enddt | TYPE SY, " | |||
| lv_begzt | TYPE SY-UZEIT, " '000000' | |||
| lv_etldt_lt_enddt | TYPE SY, " | |||
| lv_einri | TYPE TN01-EINRI, " | |||
| lv_invalid_einri | TYPE TN01, " | |||
| lv_enddt | TYPE SY-DATUM, " | |||
| lv_invalid_s_param | TYPE SY, " | |||
| lv_endzt | TYPE SY-UZEIT, " '240000' | |||
| lv_etlart | TYPE NBEW-BWART, " SPACE | |||
| lv_etldt | TYPE SY-DATUM. " '99991231' |
|   CALL FUNCTION 'ISH_GET_QUANTITY_SERVICES' "IS-H: Determines the quantity of specific services |
| EXPORTING | ||
| AUFDT | = lv_aufdt | |
| ETLZT | = lv_etlzt | |
| FALNR | = lv_falnr | |
| NBGDT | = lv_nbgdt | |
| NBGZT | = lv_nbgzt | |
| S_PARAM | = lv_s_param | |
| TALST | = lv_talst | |
| TARID | = lv_tarid | |
| AUFZT | = lv_aufzt | |
| BEGDT | = lv_begdt | |
| BEGZT | = lv_begzt | |
| EINRI | = lv_einri | |
| ENDDT | = lv_enddt | |
| ENDZT | = lv_endzt | |
| ETLART | = lv_etlart | |
| ETLDT | = lv_etldt | |
| IMPORTING | ||
| QUANTITY | = lv_quantity | |
| EXCEPTIONS | ||
| AUFDT_GT_BEGDT = 1 | ||
| AUF_GT_ETL = 2 | ||
| BEGDT_GT_ENDDT = 3 | ||
| ETLDT_LT_ENDDT = 4 | ||
| INVALID_EINRI = 5 | ||
| INVALID_S_PARAM = 6 | ||
| . " ISH_GET_QUANTITY_SERVICES | ||
ABAP code using 7.40 inline data declarations to call FM ISH_GET_QUANTITY_SERVICES
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 DATUM FROM SY INTO @DATA(ld_aufdt). | ||||
| DATA(ld_aufdt) | = '19000101'. | |||
| "SELECT single UZEIT FROM SY INTO @DATA(ld_etlzt). | ||||
| DATA(ld_etlzt) | = '240000'. | |||
| "SELECT single FALNR FROM NFAL INTO @DATA(ld_falnr). | ||||
| "SELECT single NBGDT FROM NLEI INTO @DATA(ld_nbgdt). | ||||
| DATA(ld_nbgdt) | = '00000000'. | |||
| "SELECT single NBGZT FROM NLEI INTO @DATA(ld_nbgzt). | ||||
| DATA(ld_nbgzt) | = '000000'. | |||
| "SELECT single BFORM FROM NTPK INTO @DATA(ld_s_param). | ||||
| DATA(ld_s_param) | = '01'. | |||
| "SELECT single TALST FROM NTPK INTO @DATA(ld_talst). | ||||
| DATA(ld_talst) | = ' '. | |||
| "SELECT single TARIF FROM NTPK INTO @DATA(ld_tarid). | ||||
| DATA(ld_tarid) | = ' '. | |||
| "SELECT single UZEIT FROM SY INTO @DATA(ld_aufzt). | ||||
| DATA(ld_aufzt) | = '000000'. | |||
| "SELECT single DATUM FROM SY INTO @DATA(ld_begdt). | ||||
| "SELECT single UZEIT FROM SY INTO @DATA(ld_begzt). | ||||
| DATA(ld_begzt) | = '000000'. | |||
| "SELECT single EINRI FROM TN01 INTO @DATA(ld_einri). | ||||
| "SELECT single DATUM FROM SY INTO @DATA(ld_enddt). | ||||
| "SELECT single UZEIT FROM SY INTO @DATA(ld_endzt). | ||||
| DATA(ld_endzt) | = '240000'. | |||
| "SELECT single BWART FROM NBEW INTO @DATA(ld_etlart). | ||||
| DATA(ld_etlart) | = ' '. | |||
| "SELECT single DATUM FROM SY INTO @DATA(ld_etldt). | ||||
| DATA(ld_etldt) | = '99991231'. | |||
Search for further information about these or an SAP related objects