SAP CNV_TDMS_CREATE_INDEX Function Module for Create index in parallel
CNV_TDMS_CREATE_INDEX is a standard cnv tdms create index SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Create index in parallel 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 cnv tdms create index FM, simply by entering the name CNV_TDMS_CREATE_INDEX into the relevant SAP transaction such as SE37 or SE38.
Function Group: CNV_TDMS_05_INDEX
Program Name: SAPLCNV_TDMS_05_INDEX
Main Program: SAPLCNV_TDMS_05_INDEX
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function CNV_TDMS_CREATE_INDEX 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 'CNV_TDMS_CREATE_INDEX'"Create index in parallel.
EXPORTING
* IV_DBSYS = SY-DBSYS "R/3 System, name of central database system
IV_INDEXNAME = "Unique index ID within a table
* IV_NO_EXEC = ' ' "
* IV_PRID = 0 "Internal table, current line index
* IV_PROGNAME = ' ' "ABAP program name
IV_TABNAME = "Table name
* IV_HINT = 4 "Sequence number
* IV_ONLINE = 'X' "boolean variable (X=true, -=false, space=unknown)
IMPORTING
EV_GENPROG = "ABAP program name
EXCEPTIONS
BASETAB_ERROR = 1 DB_ERROR = 2 DD_ERROR = 3 INDEX_EXISTS = 4 INDEX_NOT_CREATED = 5
IMPORTING Parameters details for CNV_TDMS_CREATE_INDEX
IV_DBSYS - R/3 System, name of central database system
Data type: SYDBSYSDefault: SY-DBSYS
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_INDEXNAME - Unique index ID within a table
Data type: INDEXIDOptional: No
Call by Reference: No ( called with pass by value option)
IV_NO_EXEC -
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_PRID - Internal table, current line index
Data type: SYTABIXOptional: Yes
Call by Reference: No ( called with pass by value option)
IV_PROGNAME - ABAP program name
Data type: PROGRAMMDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_TABNAME - Table name
Data type: TABNAMEOptional: No
Call by Reference: No ( called with pass by value option)
IV_HINT - Sequence number
Data type: CNV_TDMS_MAX_HINTDefault: 4
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_ONLINE - boolean variable (X=true, -=false, space=unknown)
Data type: BOOLEANDefault: 'X'
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for CNV_TDMS_CREATE_INDEX
EV_GENPROG - ABAP program name
Data type: PROGRAMMOptional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
BASETAB_ERROR -
Data type:Optional: No
Call by Reference: Yes
DB_ERROR -
Data type:Optional: No
Call by Reference: Yes
DD_ERROR -
Data type:Optional: No
Call by Reference: Yes
INDEX_EXISTS -
Data type:Optional: No
Call by Reference: Yes
INDEX_NOT_CREATED -
Data type:Optional: No
Call by Reference: Yes
Copy and paste ABAP code example for CNV_TDMS_CREATE_INDEX 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_iv_dbsys | TYPE SYDBSYS, " SY-DBSYS | |||
| lv_ev_genprog | TYPE PROGRAMM, " | |||
| lv_basetab_error | TYPE PROGRAMM, " | |||
| lv_db_error | TYPE PROGRAMM, " | |||
| lv_iv_indexname | TYPE INDEXID, " | |||
| lv_dd_error | TYPE INDEXID, " | |||
| lv_iv_no_exec | TYPE INDEXID, " SPACE | |||
| lv_iv_prid | TYPE SYTABIX, " 0 | |||
| lv_index_exists | TYPE SYTABIX, " | |||
| lv_iv_progname | TYPE PROGRAMM, " SPACE | |||
| lv_index_not_created | TYPE PROGRAMM, " | |||
| lv_iv_tabname | TYPE TABNAME, " | |||
| lv_iv_hint | TYPE CNV_TDMS_MAX_HINT, " 4 | |||
| lv_iv_online | TYPE BOOLEAN. " 'X' |
|   CALL FUNCTION 'CNV_TDMS_CREATE_INDEX' "Create index in parallel |
| EXPORTING | ||
| IV_DBSYS | = lv_iv_dbsys | |
| IV_INDEXNAME | = lv_iv_indexname | |
| IV_NO_EXEC | = lv_iv_no_exec | |
| IV_PRID | = lv_iv_prid | |
| IV_PROGNAME | = lv_iv_progname | |
| IV_TABNAME | = lv_iv_tabname | |
| IV_HINT | = lv_iv_hint | |
| IV_ONLINE | = lv_iv_online | |
| IMPORTING | ||
| EV_GENPROG | = lv_ev_genprog | |
| EXCEPTIONS | ||
| BASETAB_ERROR = 1 | ||
| DB_ERROR = 2 | ||
| DD_ERROR = 3 | ||
| INDEX_EXISTS = 4 | ||
| INDEX_NOT_CREATED = 5 | ||
| . " CNV_TDMS_CREATE_INDEX | ||
ABAP code using 7.40 inline data declarations to call FM CNV_TDMS_CREATE_INDEX
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.| DATA(ld_iv_dbsys) | = SY-DBSYS. | |||
| DATA(ld_iv_no_exec) | = ' '. | |||
| DATA(ld_iv_progname) | = ' '. | |||
| DATA(ld_iv_hint) | = 4. | |||
| DATA(ld_iv_online) | = 'X'. | |||
Search for further information about these or an SAP related objects