SAP QLIB_GR_QMEL_KQD Function Module for
QLIB_GR_QMEL_KQD is a standard qlib gr qmel kqd SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, 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 qlib gr qmel kqd FM, simply by entering the name QLIB_GR_QMEL_KQD into the relevant SAP transaction such as SE37 or SE38.
Function Group: QLIB
Program Name: SAPLQLIB
Main Program:
Appliation area: Q
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function QLIB_GR_QMEL_KQD 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 'QLIB_GR_QMEL_KQD'".
EXPORTING
I_DATUV = "Creation date of the Q-notification
I_EKORG = "Purchasing organization for vendor evaluation
I_LIFNR = "Vendor for vendor evaluation
* I_INITIALIZE = ' ' "Data should be read from database
I_QMUAT = "Business volume share for quality score calculation
* I_HWAERS = "Local currency key
IMPORTING
E_QKZ = "Calculated Q-score
EXCEPTIONS
NO_QMEL_FOUND = 1
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_SAPLQLIB_001 Customer Function for Selecting Lots for Vendor Evaluation
EXIT_SAPLQLIB_002 Customer Function for Calculating Q-Scores
EXIT_SAPLQLIB_003 Customer Exit: Notification Selection for Vendor Evaluation
EXIT_SAPLQLIB_004 Customer Exit: Calculation of Complaint Score
IMPORTING Parameters details for QLIB_GR_QMEL_KQD
I_DATUV - Creation date of the Q-notification
Data type: QMEL-QMDATOptional: No
Call by Reference: No ( called with pass by value option)
I_EKORG - Purchasing organization for vendor evaluation
Data type: QMEL-EKORGOptional: No
Call by Reference: No ( called with pass by value option)
I_LIFNR - Vendor for vendor evaluation
Data type: QMEL-LIFNUMOptional: No
Call by Reference: No ( called with pass by value option)
I_INITIALIZE - Data should be read from database
Data type: QM00-QKZDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
I_QMUAT - Business volume share for quality score calculation
Data type: T147-QMUATOptional: No
Call by Reference: No ( called with pass by value option)
I_HWAERS - Local currency key
Data type: SY-WAERSOptional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for QLIB_GR_QMEL_KQD
E_QKZ - Calculated Q-score
Data type: TQSS-KENNZAHLUNOptional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
NO_QMEL_FOUND - No quality notification found for entry
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for QLIB_GR_QMEL_KQD 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_e_qkz | TYPE TQSS-KENNZAHLUN, " | |||
| lv_i_datuv | TYPE QMEL-QMDAT, " | |||
| lv_no_qmel_found | TYPE QMEL, " | |||
| lv_i_ekorg | TYPE QMEL-EKORG, " | |||
| lv_i_lifnr | TYPE QMEL-LIFNUM, " | |||
| lv_i_initialize | TYPE QM00-QKZ, " SPACE | |||
| lv_i_qmuat | TYPE T147-QMUAT, " | |||
| lv_i_hwaers | TYPE SY-WAERS. " |
|   CALL FUNCTION 'QLIB_GR_QMEL_KQD' " |
| EXPORTING | ||
| I_DATUV | = lv_i_datuv | |
| I_EKORG | = lv_i_ekorg | |
| I_LIFNR | = lv_i_lifnr | |
| I_INITIALIZE | = lv_i_initialize | |
| I_QMUAT | = lv_i_qmuat | |
| I_HWAERS | = lv_i_hwaers | |
| IMPORTING | ||
| E_QKZ | = lv_e_qkz | |
| EXCEPTIONS | ||
| NO_QMEL_FOUND = 1 | ||
| . " QLIB_GR_QMEL_KQD | ||
ABAP code using 7.40 inline data declarations to call FM QLIB_GR_QMEL_KQD
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 KENNZAHLUN FROM TQSS INTO @DATA(ld_e_qkz). | ||||
| "SELECT single QMDAT FROM QMEL INTO @DATA(ld_i_datuv). | ||||
| "SELECT single EKORG FROM QMEL INTO @DATA(ld_i_ekorg). | ||||
| "SELECT single LIFNUM FROM QMEL INTO @DATA(ld_i_lifnr). | ||||
| "SELECT single QKZ FROM QM00 INTO @DATA(ld_i_initialize). | ||||
| DATA(ld_i_initialize) | = ' '. | |||
| "SELECT single QMUAT FROM T147 INTO @DATA(ld_i_qmuat). | ||||
| "SELECT single WAERS FROM SY INTO @DATA(ld_i_hwaers). | ||||
Search for further information about these or an SAP related objects