SAP QPSD_SET_VALID_READ Function Module for NOTRANSL: Lesen einer Auswahlmenge zu einem Stichtag und der Codes









QPSD_SET_VALID_READ is a standard qpsd set valid read SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for NOTRANSL: Lesen einer Auswahlmenge zu einem Stichtag und der Codes 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 qpsd set valid read FM, simply by entering the name QPSD_SET_VALID_READ into the relevant SAP transaction such as SE37 or SE38.

Function Group: QPSD
Program Name: SAPLQPSD
Main Program: SAPLQPSD
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function QPSD_SET_VALID_READ 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 'QPSD_SET_VALID_READ'"NOTRANSL: Lesen einer Auswahlmenge zu einem Stichtag und der Codes
EXPORTING
AUSWAHLMENGE = "selected set to be read
* GUELTIGAB = SY-DATUM "Key date
* I_BEL_WERK = ' ' "Ind.:Selected set available in any plant
* I_NICHTFREI = ' ' "code version to be read
KATALOGART = "catalog type to be read
* KZ_AUFLOESUNG = ' ' "ID: selected set should be deleted
* SPRACHE = SY-LANGU "code version to be read
WERK = "Plant to be read

TABLES
SELEKTIERTE_ZEILEN = "Table contains the required entries

EXCEPTIONS
NO_FREE = 1 NO_SET = 2 NO_VALID = 3
.




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_SAPLQPSD_001 Customer Exit While Reading a Master Inspection Characteristic Version

IMPORTING Parameters details for QPSD_SET_VALID_READ

AUSWAHLMENGE - selected set to be read

Data type: QPAM-AUSWAHLMGE
Optional: No
Call by Reference: No ( called with pass by value option)

GUELTIGAB - Key date

Data type: QPAC-GUELTIGAB
Default: SY-DATUM
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_BEL_WERK - Ind.:Selected set available in any plant

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

I_NICHTFREI - code version to be read

Data type: RMQSE-AUFLOESUNG
Default: ' '
Optional: Yes
Call by Reference: No ( called with pass by value option)

KATALOGART - catalog type to be read

Data type: QPAM-KATALOGART
Optional: No
Call by Reference: No ( called with pass by value option)

KZ_AUFLOESUNG - ID: selected set should be deleted

Data type: RMQSE-AUFLOESUNG
Default: ' '
Optional: Yes
Call by Reference: No ( called with pass by value option)

SPRACHE - code version to be read

Data type: QPAM-KSP01
Default: SY-LANGU
Optional: Yes
Call by Reference: No ( called with pass by value option)

WERK - Plant to be read

Data type: QPAM-WERKS
Optional: No
Call by Reference: No ( called with pass by value option)

TABLES Parameters details for QPSD_SET_VALID_READ

SELEKTIERTE_ZEILEN - Table contains the required entries

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

EXCEPTIONS details

NO_FREE - code version to be read

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

NO_SET - required selected set is not created

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

NO_VALID - there is no valid version

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

Copy and paste ABAP code example for QPSD_SET_VALID_READ 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_no_free  TYPE STRING, "   
lv_auswahlmenge  TYPE QPAM-AUSWAHLMGE, "   
lt_selektierte_zeilen  TYPE STANDARD TABLE OF QKAT, "   
lv_no_set  TYPE QKAT, "   
lv_gueltigab  TYPE QPAC-GUELTIGAB, "   SY-DATUM
lv_no_valid  TYPE QPAC, "   
lv_i_bel_werk  TYPE QPAC, "   ' '
lv_i_nichtfrei  TYPE RMQSE-AUFLOESUNG, "   ' '
lv_katalogart  TYPE QPAM-KATALOGART, "   
lv_kz_aufloesung  TYPE RMQSE-AUFLOESUNG, "   ' '
lv_sprache  TYPE QPAM-KSP01, "   SY-LANGU
lv_werk  TYPE QPAM-WERKS. "   

  CALL FUNCTION 'QPSD_SET_VALID_READ'  "NOTRANSL: Lesen einer Auswahlmenge zu einem Stichtag und der Codes
    EXPORTING
         AUSWAHLMENGE = lv_auswahlmenge
         GUELTIGAB = lv_gueltigab
         I_BEL_WERK = lv_i_bel_werk
         I_NICHTFREI = lv_i_nichtfrei
         KATALOGART = lv_katalogart
         KZ_AUFLOESUNG = lv_kz_aufloesung
         SPRACHE = lv_sprache
         WERK = lv_werk
    TABLES
         SELEKTIERTE_ZEILEN = lt_selektierte_zeilen
    EXCEPTIONS
        NO_FREE = 1
        NO_SET = 2
        NO_VALID = 3
. " QPSD_SET_VALID_READ




ABAP code using 7.40 inline data declarations to call FM QPSD_SET_VALID_READ

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 AUSWAHLMGE FROM QPAM INTO @DATA(ld_auswahlmenge).
 
 
 
"SELECT single GUELTIGAB FROM QPAC INTO @DATA(ld_gueltigab).
DATA(ld_gueltigab) = SY-DATUM.
 
 
DATA(ld_i_bel_werk) = ' '.
 
"SELECT single AUFLOESUNG FROM RMQSE INTO @DATA(ld_i_nichtfrei).
DATA(ld_i_nichtfrei) = ' '.
 
"SELECT single KATALOGART FROM QPAM INTO @DATA(ld_katalogart).
 
"SELECT single AUFLOESUNG FROM RMQSE INTO @DATA(ld_kz_aufloesung).
DATA(ld_kz_aufloesung) = ' '.
 
"SELECT single KSP01 FROM QPAM INTO @DATA(ld_sprache).
DATA(ld_sprache) = SY-LANGU.
 
"SELECT single WERKS FROM QPAM INTO @DATA(ld_werk).
 


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!