SAP CSAR_SEL_BY_DATUV Function Module for NOTRANSL: Selektion veralteter STKO / STAS Säzte und ihres Kontextes









CSAR_SEL_BY_DATUV is a standard csar sel by datuv 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: Selektion veralteter STKO / STAS Säzte und ihres Kontextes 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 csar sel by datuv FM, simply by entering the name CSAR_SEL_BY_DATUV into the relevant SAP transaction such as SE37 or SE38.

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



Function CSAR_SEL_BY_DATUV 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 'CSAR_SEL_BY_DATUV'"NOTRANSL: Selektion veralteter STKO / STAS  Säzte und ihres Kontextes
EXPORTING
* LOEKZ = ' ' "Deletion flag for BOMs
* SEL_MAST = ' ' "Generic Type
* SEL_DOST = ' ' "Generic Type
* SEL_EQST = ' ' "Generic Type
* SEL_TPST = ' ' "Generic Type
* SEL_KDST = ' ' "Generic Type
* SEL_STST = ' ' "Generic Type
* SEL_PRST = ' ' "Generic Type

TABLES
IT_MAST = "Material to BOM Link
IT_STAS = "BOMs - Item Selection
IT_STPO = "Bill of Material Item
IT_STPU = "BOM Subitem
IT_STPN = "BOM Follow-Up Control
SO_DATUV = "DE-EN-LANG-SWITCH-NO-TRANSLATION
SO_WERKS = "DE-EN-LANG-SWITCH-NO-TRANSLATION
SO_STLAN = "DE-EN-LANG-SWITCH-NO-TRANSLATION
SO_STLNR = "DE-EN-LANG-SWITCH-NO-TRANSLATION
SO_STLAL = "DE-EN-LANG-SWITCH-NO-TRANSLATION
IT_DOST = "Document to BOM Link
IT_EQST = "Equipment to BOM Link
IT_TPST = "Link Between Functional Location and BOM
IT_KDST = "Sales Order to BOM Link
IT_STST = "Standard BOM Link
IT_PRST = "Project - BOM link
IT_STZU = "Permanent BOM Data
REF_STKO = "Bill Of Material Header

EXCEPTIONS
DATUV_IS_INITIAL = 1 NO_STLTY = 2
.



IMPORTING Parameters details for CSAR_SEL_BY_DATUV

LOEKZ - Deletion flag for BOMs

Data type: STKO-LOEKZ
Default: ' '
Optional: Yes
Call by Reference: Yes

SEL_MAST - Generic Type

Data type: C
Default: ' '
Optional: Yes
Call by Reference: Yes

SEL_DOST - Generic Type

Data type: C
Default: ' '
Optional: Yes
Call by Reference: Yes

SEL_EQST - Generic Type

Data type: C
Default: ' '
Optional: Yes
Call by Reference: Yes

SEL_TPST - Generic Type

Data type: C
Default: ' '
Optional: Yes
Call by Reference: Yes

SEL_KDST - Generic Type

Data type: C
Default: ' '
Optional: Yes
Call by Reference: Yes

SEL_STST - Generic Type

Data type: C
Default: ' '
Optional: Yes
Call by Reference: Yes

SEL_PRST - Generic Type

Data type: C
Default: ' '
Optional: Yes
Call by Reference: Yes

TABLES Parameters details for CSAR_SEL_BY_DATUV

IT_MAST - Material to BOM Link

Data type: MAST
Optional: No
Call by Reference: Yes

IT_STAS - BOMs - Item Selection

Data type: STAS
Optional: No
Call by Reference: Yes

IT_STPO - Bill of Material Item

Data type: STPO
Optional: No
Call by Reference: Yes

IT_STPU - BOM Subitem

Data type: STPU
Optional: No
Call by Reference: Yes

IT_STPN - BOM Follow-Up Control

Data type: STPN
Optional: No
Call by Reference: Yes

SO_DATUV - DE-EN-LANG-SWITCH-NO-TRANSLATION

Data type: CSAR_SO_DATUV_TAB
Optional: No
Call by Reference: Yes

SO_WERKS - DE-EN-LANG-SWITCH-NO-TRANSLATION

Data type: CSAR_SO_WERKS_TAB
Optional: No
Call by Reference: Yes

SO_STLAN - DE-EN-LANG-SWITCH-NO-TRANSLATION

Data type: CSAR_SO_STLAN_TAB
Optional: No
Call by Reference: Yes

SO_STLNR - DE-EN-LANG-SWITCH-NO-TRANSLATION

Data type: CSAR_SO_STLNR_TAB
Optional: No
Call by Reference: Yes

SO_STLAL - DE-EN-LANG-SWITCH-NO-TRANSLATION

Data type: CSAR_SO_STLAL_TAB
Optional: No
Call by Reference: Yes

IT_DOST - Document to BOM Link

Data type: DOST
Optional: No
Call by Reference: Yes

IT_EQST - Equipment to BOM Link

Data type: EQST
Optional: No
Call by Reference: Yes

IT_TPST - Link Between Functional Location and BOM

Data type: TPST
Optional: No
Call by Reference: Yes

IT_KDST - Sales Order to BOM Link

Data type: KDST
Optional: No
Call by Reference: Yes

IT_STST - Standard BOM Link

Data type: STST
Optional: No
Call by Reference: Yes

IT_PRST - Project - BOM link

Data type: PRST
Optional: No
Call by Reference: Yes

IT_STZU - Permanent BOM Data

Data type: STZU
Optional: No
Call by Reference: Yes

REF_STKO - Bill Of Material Header

Data type: STKOAR
Optional: No
Call by Reference: Yes

EXCEPTIONS details

DATUV_IS_INITIAL - DE-EN-LANG-SWITCH-NO-TRANSLATION

Data type:
Optional: No
Call by Reference: Yes

NO_STLTY - DE-EN-LANG-SWITCH-NO-TRANSLATION

Data type:
Optional: No
Call by Reference: Yes

Copy and paste ABAP code example for CSAR_SEL_BY_DATUV 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_loekz  TYPE STKO-LOEKZ, "   ' '
lt_it_mast  TYPE STANDARD TABLE OF MAST, "   
lv_datuv_is_initial  TYPE MAST, "   
lt_it_stas  TYPE STANDARD TABLE OF STAS, "   
lt_it_stpo  TYPE STANDARD TABLE OF STPO, "   
lt_it_stpu  TYPE STANDARD TABLE OF STPU, "   
lt_it_stpn  TYPE STANDARD TABLE OF STPN, "   
lt_so_datuv  TYPE STANDARD TABLE OF CSAR_SO_DATUV_TAB, "   
lt_so_werks  TYPE STANDARD TABLE OF CSAR_SO_WERKS_TAB, "   
lt_so_stlan  TYPE STANDARD TABLE OF CSAR_SO_STLAN_TAB, "   
lt_so_stlnr  TYPE STANDARD TABLE OF CSAR_SO_STLNR_TAB, "   
lt_so_stlal  TYPE STANDARD TABLE OF CSAR_SO_STLAL_TAB, "   
lt_it_dost  TYPE STANDARD TABLE OF DOST, "   
lv_no_stlty  TYPE DOST, "   
lv_sel_mast  TYPE C, "   ' '
lt_it_eqst  TYPE STANDARD TABLE OF EQST, "   
lv_sel_dost  TYPE C, "   ' '
lt_it_tpst  TYPE STANDARD TABLE OF TPST, "   
lv_sel_eqst  TYPE C, "   ' '
lt_it_kdst  TYPE STANDARD TABLE OF KDST, "   
lv_sel_tpst  TYPE C, "   ' '
lt_it_stst  TYPE STANDARD TABLE OF STST, "   
lv_sel_kdst  TYPE C, "   ' '
lt_it_prst  TYPE STANDARD TABLE OF PRST, "   
lv_sel_stst  TYPE C, "   ' '
lt_it_stzu  TYPE STANDARD TABLE OF STZU, "   
lv_sel_prst  TYPE C, "   ' '
lt_ref_stko  TYPE STANDARD TABLE OF STKOAR. "   

  CALL FUNCTION 'CSAR_SEL_BY_DATUV'  "NOTRANSL: Selektion veralteter STKO / STAS Säzte und ihres Kontextes
    EXPORTING
         LOEKZ = lv_loekz
         SEL_MAST = lv_sel_mast
         SEL_DOST = lv_sel_dost
         SEL_EQST = lv_sel_eqst
         SEL_TPST = lv_sel_tpst
         SEL_KDST = lv_sel_kdst
         SEL_STST = lv_sel_stst
         SEL_PRST = lv_sel_prst
    TABLES
         IT_MAST = lt_it_mast
         IT_STAS = lt_it_stas
         IT_STPO = lt_it_stpo
         IT_STPU = lt_it_stpu
         IT_STPN = lt_it_stpn
         SO_DATUV = lt_so_datuv
         SO_WERKS = lt_so_werks
         SO_STLAN = lt_so_stlan
         SO_STLNR = lt_so_stlnr
         SO_STLAL = lt_so_stlal
         IT_DOST = lt_it_dost
         IT_EQST = lt_it_eqst
         IT_TPST = lt_it_tpst
         IT_KDST = lt_it_kdst
         IT_STST = lt_it_stst
         IT_PRST = lt_it_prst
         IT_STZU = lt_it_stzu
         REF_STKO = lt_ref_stko
    EXCEPTIONS
        DATUV_IS_INITIAL = 1
        NO_STLTY = 2
. " CSAR_SEL_BY_DATUV




ABAP code using 7.40 inline data declarations to call FM CSAR_SEL_BY_DATUV

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 LOEKZ FROM STKO INTO @DATA(ld_loekz).
DATA(ld_loekz) = ' '.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
DATA(ld_sel_mast) = ' '.
 
 
DATA(ld_sel_dost) = ' '.
 
 
DATA(ld_sel_eqst) = ' '.
 
 
DATA(ld_sel_tpst) = ' '.
 
 
DATA(ld_sel_kdst) = ' '.
 
 
DATA(ld_sel_stst) = ' '.
 
 
DATA(ld_sel_prst) = ' '.
 
 


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!