SAP TREX_ARW_CREATE_INDEX Function Module for Create Index









TREX_ARW_CREATE_INDEX is a standard trex arw 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 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 trex arw create index FM, simply by entering the name TREX_ARW_CREATE_INDEX into the relevant SAP transaction such as SE37 or SE38.

Function Group: TREX_ARW_ADMINISTRATION
Program Name: SAPLTREX_ARW_ADMINISTRATION
Main Program: SAPLTREX_ARW_ADMINISTRATION
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Remote-Enabled
Update:



Function TREX_ARW_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 'TREX_ARW_CREATE_INDEX'"Create Index
EXPORTING
INDEX_ID = "Index Id
* MEMORY_INDEX = "Memory index
* KEEP_CONTENT = "Content is stored on disk
* PRECALCULATE_FEATURES = "Document features are calculated and stored on disk
* IS_SEARCHABLE = "Index can be used for searching
* AUTO_CREATE_LANGUAGES = "Language indexes are created automatically
* DUPLICATE_DETECTION = "Flag
* SIZE_FOR_DELTA_INDEX = "numc Feld
* MULTILANG_DOCS = "Flag
* INDEX_TYPE = "Flag
* LOGICAL_INDEX_TYPE = "Flag
RFC_DESTINATION = "RFC Destination
* USE_EXTERNAL_KEY = "Indicator
* DIRECT_USE = "Indicator
* IMPORT_WRITABLE = "Indicator
* IMPORT_PATH = "Import Path
* ESTIMATED_SIZE = "NUMC10 e.g.for estimated_size
* INSERT_ONLY = "Indicator
* TOKEN_SEPARATOR = "
* NUMBER_SEPARATOR = "
* FAST_PREPROCESSING = "Indicator
* ALL_ATTRS_FREESTYLE = "Indicator
* LANGUAGE = "Language
* NO_PHYSICAL_INDEXES = "
* DOCS_CHANGE_LANGUAGE = "Indicator
* USE_TEMPORARY_DELTA_INDEXES = "Indicator
* FAST_UPDATE_WITH_TEMP_DELTA = "Indicator
* DESCRIPTION = "Description
* INDEXSERVER_LOCATION = "Host and Port of the index server
* USE_QUEUESERVER = "'X': Queue server is used
* QUEUESERVER_LOCATION = "Host and Port of the queue server
* IS_PUBLIC = "'X': Index is published
* TEXTMINING_RELEVANT = "Text mining relevant

IMPORTING
RETURN_CODE = "Return code
RETURN_TEXT = "Return text

TABLES
* ATTRIBUTE_DEFINITIONS = "Attribut definitions
* PHYSICAL_INDEXES = "
* LANGUAGE_INDEXES = "
* EXTENSIONS = "Extensions
* KEY_ATTRIBUTES = "RAW: Attributes
* FREESTYLE_SEARCH_ATTRIBUTES = "RAW: Attributes
* PRELOAD_ATTRIBUTES = "RAW: Attributes
* PRELOAD_LANGUAGES = "RAW: Language (ISO 639)
* PARTITION_ATTRIBUTES = "RAW: Attributes

EXCEPTIONS
CONVERSION_ERROR = 1 ERROR = 2
.



IMPORTING Parameters details for TREX_ARW_CREATE_INDEX

INDEX_ID - Index Id

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

MEMORY_INDEX - Memory index

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

KEEP_CONTENT - Content is stored on disk

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

PRECALCULATE_FEATURES - Document features are calculated and stored on disk

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

IS_SEARCHABLE - Index can be used for searching

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

AUTO_CREATE_LANGUAGES - Language indexes are created automatically

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

DUPLICATE_DETECTION - Flag

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

SIZE_FOR_DELTA_INDEX - numc Feld

Data type: TREXX_RFC-NUMC
Optional: Yes
Call by Reference: No ( called with pass by value option)

MULTILANG_DOCS - Flag

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

INDEX_TYPE - Flag

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

LOGICAL_INDEX_TYPE - Flag

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

RFC_DESTINATION - RFC Destination

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

USE_EXTERNAL_KEY - Indicator

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

DIRECT_USE - Indicator

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

IMPORT_WRITABLE - Indicator

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

IMPORT_PATH - Import Path

Data type: TREXX_RFC-PATH
Optional: Yes
Call by Reference: No ( called with pass by value option)

ESTIMATED_SIZE - NUMC10 e.g.for estimated_size

Data type: TREXX_RFC-NUMC10
Optional: Yes
Call by Reference: No ( called with pass by value option)

INSERT_ONLY - Indicator

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

TOKEN_SEPARATOR -

Data type: TREXX_RFC-SEPARATOR
Optional: Yes
Call by Reference: No ( called with pass by value option)

NUMBER_SEPARATOR -

Data type: TREXX_RFC-SEPARATOR
Optional: Yes
Call by Reference: No ( called with pass by value option)

FAST_PREPROCESSING - Indicator

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

ALL_ATTRS_FREESTYLE - Indicator

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

LANGUAGE - Language

Data type: TREXX_RFC-LANGUAGE
Optional: Yes
Call by Reference: No ( called with pass by value option)

NO_PHYSICAL_INDEXES -

Data type: TREXX_RFC-NUMC
Optional: Yes
Call by Reference: No ( called with pass by value option)

DOCS_CHANGE_LANGUAGE - Indicator

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

USE_TEMPORARY_DELTA_INDEXES - Indicator

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

FAST_UPDATE_WITH_TEMP_DELTA - Indicator

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

DESCRIPTION - Description

Data type: TREXX_RFC-DESCRIPTION
Optional: Yes
Call by Reference: No ( called with pass by value option)

INDEXSERVER_LOCATION - Host and Port of the index server

Data type: TREXX_RFC-LOCATION
Optional: Yes
Call by Reference: No ( called with pass by value option)

USE_QUEUESERVER - 'X': Queue server is used

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

QUEUESERVER_LOCATION - Host and Port of the queue server

Data type: TREXX_RFC-LOCATION
Optional: Yes
Call by Reference: No ( called with pass by value option)

IS_PUBLIC - 'X': Index is published

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

TEXTMINING_RELEVANT - Text mining relevant

Data type: TREXX_RFC-FLAG
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXPORTING Parameters details for TREX_ARW_CREATE_INDEX

RETURN_CODE - Return code

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

RETURN_TEXT - Return text

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

TABLES Parameters details for TREX_ARW_CREATE_INDEX

ATTRIBUTE_DEFINITIONS - Attribut definitions

Data type: TREXX_ATTR_DEF_V2
Optional: Yes
Call by Reference: Yes

PHYSICAL_INDEXES -

Data type: TREXX_INDEXES
Optional: Yes
Call by Reference: Yes

LANGUAGE_INDEXES -

Data type: TREXX_INDEXES
Optional: Yes
Call by Reference: Yes

EXTENSIONS - Extensions

Data type: TREXX_EXTENSIONS
Optional: Yes
Call by Reference: Yes

KEY_ATTRIBUTES - RAW: Attributes

Data type: TREXX_ATTRIBUTES
Optional: Yes
Call by Reference: Yes

FREESTYLE_SEARCH_ATTRIBUTES - RAW: Attributes

Data type: TREXX_ATTRIBUTES
Optional: Yes
Call by Reference: Yes

PRELOAD_ATTRIBUTES - RAW: Attributes

Data type: TREXX_ATTRIBUTES
Optional: Yes
Call by Reference: Yes

PRELOAD_LANGUAGES - RAW: Language (ISO 639)

Data type: TREXX_LANGUAGE
Optional: Yes
Call by Reference: Yes

PARTITION_ATTRIBUTES - RAW: Attributes

Data type: TREXX_ATTRIBUTES
Optional: Yes
Call by Reference: Yes

EXCEPTIONS details

CONVERSION_ERROR - Error during conversion to UTF-8

Data type:
Optional: No
Call by Reference: Yes

ERROR - Error, see error message

Data type:
Optional: No
Call by Reference: Yes

Copy and paste ABAP code example for TREX_ARW_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_index_id  TYPE TREXX_RFC-INDEX_ID, "   
lv_return_code  TYPE TREXX_RFC-RETURN_CODE, "   
lv_conversion_error  TYPE TREXX_RFC, "   
lt_attribute_definitions  TYPE STANDARD TABLE OF TREXX_ATTR_DEF_V2, "   
lv_memory_index  TYPE TREXX_RFC-FLAG, "   
lv_keep_content  TYPE TREXX_RFC-FLAG, "   
lv_precalculate_features  TYPE TREXX_RFC-FLAG, "   
lv_is_searchable  TYPE TREXX_RFC-FLAG, "   
lv_auto_create_languages  TYPE TREXX_RFC-FLAG, "   
lv_duplicate_detection  TYPE TREXX_RFC-FLAG, "   
lv_size_for_delta_index  TYPE TREXX_RFC-NUMC, "   
lv_multilang_docs  TYPE TREXX_RFC-FLAG, "   
lv_index_type  TYPE TREXX_RFC-FLAG, "   
lv_logical_index_type  TYPE TREXX_RFC-FLAG, "   
lv_error  TYPE TREXX_RFC, "   
lv_return_text  TYPE TREXX_RFC-RETURN_TEXT, "   
lv_rfc_destination  TYPE TREXX_RFC-RFC_DESTINATION, "   
lt_physical_indexes  TYPE STANDARD TABLE OF TREXX_INDEXES, "   
lv_use_external_key  TYPE TREXX_RFC-FLAG, "   
lv_direct_use  TYPE TREXX_RFC-FLAG, "   
lv_import_writable  TYPE TREXX_RFC-FLAG, "   
lv_import_path  TYPE TREXX_RFC-PATH, "   
lv_estimated_size  TYPE TREXX_RFC-NUMC10, "   
lv_insert_only  TYPE TREXX_RFC-FLAG, "   
lv_token_separator  TYPE TREXX_RFC-SEPARATOR, "   
lv_number_separator  TYPE TREXX_RFC-SEPARATOR, "   
lv_fast_preprocessing  TYPE TREXX_RFC-FLAG, "   
lv_all_attrs_freestyle  TYPE TREXX_RFC-FLAG, "   
lv_language  TYPE TREXX_RFC-LANGUAGE, "   
lt_language_indexes  TYPE STANDARD TABLE OF TREXX_INDEXES, "   
lv_no_physical_indexes  TYPE TREXX_RFC-NUMC, "   
lv_docs_change_language  TYPE TREXX_RFC-FLAG, "   
lv_use_temporary_delta_indexes  TYPE TREXX_RFC-FLAG, "   
lv_fast_update_with_temp_delta  TYPE TREXX_RFC-FLAG, "   
lt_extensions  TYPE STANDARD TABLE OF TREXX_EXTENSIONS, "   
lv_description  TYPE TREXX_RFC-DESCRIPTION, "   
lt_key_attributes  TYPE STANDARD TABLE OF TREXX_ATTRIBUTES, "   
lv_indexserver_location  TYPE TREXX_RFC-LOCATION, "   
lv_use_queueserver  TYPE TREXX_RFC-FLAG, "   
lt_freestyle_search_attributes  TYPE STANDARD TABLE OF TREXX_ATTRIBUTES, "   
lt_preload_attributes  TYPE STANDARD TABLE OF TREXX_ATTRIBUTES, "   
lv_queueserver_location  TYPE TREXX_RFC-LOCATION, "   
lv_is_public  TYPE TREXX_RFC-FLAG, "   
lt_preload_languages  TYPE STANDARD TABLE OF TREXX_LANGUAGE, "   
lv_textmining_relevant  TYPE TREXX_RFC-FLAG, "   
lt_partition_attributes  TYPE STANDARD TABLE OF TREXX_ATTRIBUTES. "   

  CALL FUNCTION 'TREX_ARW_CREATE_INDEX'  "Create Index
    EXPORTING
         INDEX_ID = lv_index_id
         MEMORY_INDEX = lv_memory_index
         KEEP_CONTENT = lv_keep_content
         PRECALCULATE_FEATURES = lv_precalculate_features
         IS_SEARCHABLE = lv_is_searchable
         AUTO_CREATE_LANGUAGES = lv_auto_create_languages
         DUPLICATE_DETECTION = lv_duplicate_detection
         SIZE_FOR_DELTA_INDEX = lv_size_for_delta_index
         MULTILANG_DOCS = lv_multilang_docs
         INDEX_TYPE = lv_index_type
         LOGICAL_INDEX_TYPE = lv_logical_index_type
         RFC_DESTINATION = lv_rfc_destination
         USE_EXTERNAL_KEY = lv_use_external_key
         DIRECT_USE = lv_direct_use
         IMPORT_WRITABLE = lv_import_writable
         IMPORT_PATH = lv_import_path
         ESTIMATED_SIZE = lv_estimated_size
         INSERT_ONLY = lv_insert_only
         TOKEN_SEPARATOR = lv_token_separator
         NUMBER_SEPARATOR = lv_number_separator
         FAST_PREPROCESSING = lv_fast_preprocessing
         ALL_ATTRS_FREESTYLE = lv_all_attrs_freestyle
         LANGUAGE = lv_language
         NO_PHYSICAL_INDEXES = lv_no_physical_indexes
         DOCS_CHANGE_LANGUAGE = lv_docs_change_language
         USE_TEMPORARY_DELTA_INDEXES = lv_use_temporary_delta_indexes
         FAST_UPDATE_WITH_TEMP_DELTA = lv_fast_update_with_temp_delta
         DESCRIPTION = lv_description
         INDEXSERVER_LOCATION = lv_indexserver_location
         USE_QUEUESERVER = lv_use_queueserver
         QUEUESERVER_LOCATION = lv_queueserver_location
         IS_PUBLIC = lv_is_public
         TEXTMINING_RELEVANT = lv_textmining_relevant
    IMPORTING
         RETURN_CODE = lv_return_code
         RETURN_TEXT = lv_return_text
    TABLES
         ATTRIBUTE_DEFINITIONS = lt_attribute_definitions
         PHYSICAL_INDEXES = lt_physical_indexes
         LANGUAGE_INDEXES = lt_language_indexes
         EXTENSIONS = lt_extensions
         KEY_ATTRIBUTES = lt_key_attributes
         FREESTYLE_SEARCH_ATTRIBUTES = lt_freestyle_search_attributes
         PRELOAD_ATTRIBUTES = lt_preload_attributes
         PRELOAD_LANGUAGES = lt_preload_languages
         PARTITION_ATTRIBUTES = lt_partition_attributes
    EXCEPTIONS
        CONVERSION_ERROR = 1
        ERROR = 2
. " TREX_ARW_CREATE_INDEX




ABAP code using 7.40 inline data declarations to call FM TREX_ARW_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.

"SELECT single INDEX_ID FROM TREXX_RFC INTO @DATA(ld_index_id).
 
"SELECT single RETURN_CODE FROM TREXX_RFC INTO @DATA(ld_return_code).
 
 
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_memory_index).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_keep_content).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_precalculate_features).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_is_searchable).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_auto_create_languages).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_duplicate_detection).
 
"SELECT single NUMC FROM TREXX_RFC INTO @DATA(ld_size_for_delta_index).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_multilang_docs).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_index_type).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_logical_index_type).
 
 
"SELECT single RETURN_TEXT FROM TREXX_RFC INTO @DATA(ld_return_text).
 
"SELECT single RFC_DESTINATION FROM TREXX_RFC INTO @DATA(ld_rfc_destination).
 
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_use_external_key).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_direct_use).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_import_writable).
 
"SELECT single PATH FROM TREXX_RFC INTO @DATA(ld_import_path).
 
"SELECT single NUMC10 FROM TREXX_RFC INTO @DATA(ld_estimated_size).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_insert_only).
 
"SELECT single SEPARATOR FROM TREXX_RFC INTO @DATA(ld_token_separator).
 
"SELECT single SEPARATOR FROM TREXX_RFC INTO @DATA(ld_number_separator).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_fast_preprocessing).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_all_attrs_freestyle).
 
"SELECT single LANGUAGE FROM TREXX_RFC INTO @DATA(ld_language).
 
 
"SELECT single NUMC FROM TREXX_RFC INTO @DATA(ld_no_physical_indexes).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_docs_change_language).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_use_temporary_delta_indexes).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_fast_update_with_temp_delta).
 
 
"SELECT single DESCRIPTION FROM TREXX_RFC INTO @DATA(ld_description).
 
 
"SELECT single LOCATION FROM TREXX_RFC INTO @DATA(ld_indexserver_location).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_use_queueserver).
 
 
 
"SELECT single LOCATION FROM TREXX_RFC INTO @DATA(ld_queueserver_location).
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_is_public).
 
 
"SELECT single FLAG FROM TREXX_RFC INTO @DATA(ld_textmining_relevant).
 
 


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!