COPY SAP Method Copy source object nodes according to copy profile









Below is documentation, parameters and attributes of ABAP Method COPY within SAP class /SCMTMS/CL_COPY_CONTROL. There is also a number of example ABAP code snipts to help you use the functionality of this method.

This method is available within SAP systems depending on your version and release level, you can view further information by entering the class name /SCMTMS/CL_COPY_CONTROL into the relevant SAP transactions such as SE24 or SE80, and then selecting the method you are interested in.


Method Type - Static

This is a Static Method so you can call it directly

The following technical details of method COPY can also be found below:

  • Importing parameters
  • Exporting parameters
  • Changing parameters
  • Returning parameters
  • Exceptions
  • Coding Examples


Parameters of Method COPY

.

NameTypeData TypeDescriptionDefault Value
IT_ATTR_VALUESImportingTYPE
TT_ATTRIBUTE_VALUE
Attribute values to be overwritten in the target instance
IT_EXCL_NODE_INSTImportingTYPE
/BOBF/T_FRW_KEY
Node instances that shall not be copied
IT_NODE_FILTERImportingTYPE
/SCMTMS/T_CCNF_K
Node Filter
IT_NODE_FORBIDDENImportingTYPE
/SCMTMS/CL_COCO_REQUEST=>TT_BO_NODE_SCOPE
Single-Character Flag
IV_COPY_NUMBERImportingTYPE
INT2
Number of copies
IV_ENTRY_BO_NODEImportingTYPE
/BOBF/CONF_KEY
Entry node of copy, if not the root node
IV_MODIFY_TARGETImportingTYPE
FLAG
Create/Update target instances
IV_PROCESS_IDImportingTYPE
/SCMTMS/COCO_PROCESS_ID
Copy control profile ID
IV_PROFILE_IDImportingTYPE
/SCMTMS/COCO_PROFILE_ID
Copy control profile ID
IV_SOURCE_BO_KEYImportingTYPE
/BOBF/OBM_BO_KEY
Source business object for a simple copy
IV_STRATEGYImportingTYPE
/SCMTMS/COCO_STRATEGY
Process Controller Strategy for Business Object Copy
EO_MESSAGEExportingTYPE REF TO
/BOBF/IF_FRW_MESSAGE
Instance Message Object
ET_ALL_KEY_LINKSExportingTYPE
TT_KEY_LINK_EXT
All node instance links
ET_FAILED_KEYExportingTYPE
/BOBF/T_FRW_KEY
Failed BO Key Table
ET_KEY_LINK_ADDRExportingTYPE
/SCMTMS/CL_COCO_REQUEST=>TT_KEY_LINK_ADDR
ET_MODExportingTYPE
/BOBF/T_FRW_MODIFICATION
Created modification table
CT_NODE_SRC_TARGET_KEYChangingTYPE
TT_KEY_LINK_EXT
Key link table: source / target node key for copying
CT_SRC_TARGET_KEYChangingTYPE
/BOBF/T_FRW_KEY_LINK
Key link table: source / target root node for copying



Exceptions of Method COPY

This method does not have any exceptions

Example ABAP coding


DATA: lv_CT_NODE_SRC_TARGET_KEY TYPE TT_KEY_LINK_EXT,
lv_CT_SRC_TARGET_KEY TYPE /BOBF/T_FRW_KEY_LINK,
lv_EO_MESSAGE TYPE /BOBF/IF_FRW_MESSAGE,
lv_ET_ALL_KEY_LINKS TYPE TT_KEY_LINK_EXT,
lv_ET_FAILED_KEY TYPE /BOBF/T_FRW_KEY,
lv_ET_KEY_LINK_ADDR TYPE /SCMTMS/CL_COCO_REQUEST=>TT_KEY_LINK_ADDR,
lv_ET_MOD TYPE /BOBF/T_FRW_MODIFICATION,
lv_IT_ATTR_VALUES TYPE TT_ATTRIBUTE_VALUE,
lv_IT_EXCL_NODE_INST TYPE /BOBF/T_FRW_KEY,
lv_IT_NODE_FILTER TYPE /SCMTMS/T_CCNF_K,
lv_IT_NODE_FORBIDDEN TYPE /SCMTMS/CL_COCO_REQUEST=>TT_BO_NODE_SCOPE,
lv_IV_COPY_NUMBER TYPE INT2,
lv_IV_ENTRY_BO_NODE TYPE /BOBF/CONF_KEY,
lv_IV_MODIFY_TARGET TYPE FLAG,
lv_IV_PROCESS_ID TYPE /SCMTMS/COCO_PROCESS_ID,
lv_IV_PROFILE_ID TYPE /SCMTMS/COCO_PROFILE_ID,
lv_IV_SOURCE_BO_KEY TYPE /BOBF/OBM_BO_KEY,
lv_IV_STRATEGY TYPE /SCMTMS/COCO_STRATEGY,
lv_other TYPE c.

CALL METHOD /SCMTMS/CL_COPY_CONTROL=>COPY(
EXPORTING
IT_ATTR_VALUES = lv_IT_ATTR_VALUES
IT_EXCL_NODE_INST = lv_IT_EXCL_NODE_INST
IT_NODE_FILTER = lv_IT_NODE_FILTER
IT_NODE_FORBIDDEN = lv_IT_NODE_FORBIDDEN
IV_COPY_NUMBER = lv_IV_COPY_NUMBER
IV_ENTRY_BO_NODE = lv_IV_ENTRY_BO_NODE
IV_MODIFY_TARGET = lv_IV_MODIFY_TARGET
IV_PROCESS_ID = lv_IV_PROCESS_ID
IV_PROFILE_ID = lv_IV_PROFILE_ID
IV_SOURCE_BO_KEY = lv_IV_SOURCE_BO_KEY
IV_STRATEGY = lv_IV_STRATEGY
IMPORTING
EO_MESSAGE = lv_EO_MESSAGE
ET_ALL_KEY_LINKS = lv_ET_ALL_KEY_LINKS
ET_FAILED_KEY = lv_ET_FAILED_KEY
ET_KEY_LINK_ADDR = lv_ET_KEY_LINK_ADDR
ET_MOD = lv_ET_MOD
CHANGING
CT_NODE_SRC_TARGET_KEY = lv_CT_NODE_SRC_TARGET_KEY
CT_SRC_TARGET_KEY = lv_CT_SRC_TARGET_KEY ).

Links to Related Class(s)

/SCMTMS/...
Full list of available SAP object classes

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!