Copying Application Data 
The Data Manager allows you to define a package to copy the data within a range or scope using the process chain /CPMB/COPY.
Note
If the source and destination packages have different dimensionality, you must map the dimensions using a transformation file. See Data Transformations (for the Microsoft platform) and Data Transformation Maintenance (for the NetWeaver platform).
Create a package using the corresponding process chains for copying data (see Package Usage).
Run the package.
Log onto the Planning and Consolidation Office client.
Choose .
Choose the package you created in step 1 and choose Run.
Select one of the following methods to copy the data:
Choose Merge data values.
Choose Replace and clear data values.
To run default logic after the copy process, choose Yes.
To check the work status when importing the data, choose Yes.
Select the data regions for the source and destination.
Choose one of the following options:
Run now
Schedule
Run now & schedule
Choose Finish.
Note
You can change the default package instructions (see Modifying the Dynamic Script of a Package).
Dynamic script task parameters
Task: /CPMB/CLEAR_SOURCE_CUBE
|
Task |
Parameter |
Default Value |
Description |
|---|---|---|---|
|
/CPMB/CLEAR_SOURCE_CUBE |
CHECKLCK |
0 |
Check work status 1 = YES 0 = NO |
|
/CPMB/CLEAR_SOURCE_CUBE |
RUNLOGIC |
0 |
INTERNAL |
|
/CPMB/CLEAR_SOURCE_CUBE |
SELECTION |
INTERNAL |
|
|
/CPMB/CLEAR_SOURCE_CUBE |
SPACKAGE_SIZE |
40.000 |
Package size |
|
/CPMB/CM_CONVERT |
SELECTION |
Selection |
|
|
/CPMB/CM_CONVERT |
SPACKAGE_SIZE |
40.000 |
Package size |
|
/CPMB/CM_CONVERT |
TOSELECTION |
Selection destination |
|
|
/CPMB/CLEAR_SOURCE_CUBE |
CLEARDATA |
0 |
Delete data before writing 0 = NO 1= YES |
|
/CPMB/APPEND_LOAD |
CHCKLCK |
0 |
Check work status 1 = YES 0 = NO |
|
/CPMB/APPEND_LOAD |
RUNLOGIC |
0 |
Run logic after process 0 = NO 1 = YES |
|
/CPMB/CLEAR_SOURCE_CUBE |
CLEARDATA |
0 |
Delete data before writing 0 = NO 1= YES |
Example
Script
PROMPT(RADIOBUTTON,%CLEARDATA%,"Select the method for copying the data from the source to destination database",0,{"Merge data values (Copies specified records, leaving all remaining records in the destination intact)","Replace && clear data values(Copies specified records, and clears the data values for any records that mirror each entity/category/time combination defined in the source)"},{"0","1"})
PROMPT(RADIOBUTTON,%RUNLOGIC%,"Select whether to run default logic for stored values after copying",0,{"Yes","No"},{"1","0"})
PROMPT(RADIOBUTTON,%CHECKLCK%,"Select whether to check work status settings when importing data.",1,{"Yes, check for work status settings before importing","No, do not check work status settings"},{"1","0"})
PROMPT(COPYMOVEINPUT,%SELECTION%,%TOSELECTION%,"Select the members to COPY and where to","%DIMS%")
INFO(%TEMPNO1%,%INCREASENO%)
INFO(%ACTNO%,%INCREASENO%)
TASK(/CPMB/CM_CONVERT,OUTPUTNO,%TEMPNO1%)
TASK(/CPMB/CM_CONVERT,ACT_FILE_NO,%ACTNO%)
TASK(/CPMB/CM_CONVERT,SAPPSET,%APPSET%)
TASK(/CPMB/CM_CONVERT,SAPP,%APP%)
TASK(/CPMB/CM_CONVERT,SELECTION,%SELECTION%)
TASK(/CPMB/CM_CONVERT,TOSELECTION,%TOSELECTION%)
TASK(/CPMB/CM_CONVERT,CLEARDATA,%CLEARDATA%)
TASK(/CPMB/CLEAR_SOURCE_CUBE,CHECKLCK,%CHECKLCK%)
TASK(/CPMB/CLEAR_SOURCE_CUBE,SELECTION,%TOSELECTION%)
TASK(/CPMB/APPEND_LOAD,INPUTNO,%TEMPNO1%)
TASK(/CPMB/APPEND_LOAD,ACT_FILE_NO,%ACTNO%)
TASK(/CPMB/APPEND_LOAD,RUNLOGIC,%RUNLOGIC%)
TASK(/CPMB/APPEND_LOAD,CHECKLCK,%CHECKLCK%)
TASK(/CPMB/APPEND_LOAD,CLEARDATA,%CLEARDATA%)
Data
The transaction data in the target selection is cleared to zero first, then all the transaction data in the source selection is written to the target. The transaction data in the source is not affected after the copy.
When set option = Merge, this means CLEARDATA=0:
Example1:
Source selection: Entity=CASH
Target selection: Entity=CASH1
Data in the application before the copy:
ACTUAL,CASH,2006.MAY,200
ACTUAL,CASH,2006.JULY,300
ACTUAL,CASH1,2006.MAY,100
ACTUAL,CASH1,2006.JUNE,150
Data in the application after the copy:
ACTUAL,CASH,2006.MAY,200
ACTUAL,CASH,2006.JULY,300
ACTUAL,CASH1,2006.MAY,200
ACTUAL,CASH1,2006.JUNE,0
ACTUAL,CASH1,2006.JULY,300
Example 2:
Source selection: Time=2006.MAY, DataSrc = INPUT
Target selection: Time=2006.JULY, DataSrc = INPUT
Data in the application before the copy:
INPUT, ACTUAL,CASH, LC, 2006.MAY,200
INPUT, ACTUAL,CASH, USD, 2006.MAY,100
INPUT, ACTUAL,CASH, LC, 2006.JULY,300
INPUT, ACTUAL, CASH, USD, 2006. AUG, 500
NO_IP, ACTUAL,CASH,LC, 2006.JULY,150
MANU, ACTUAL,CASH,LC, 2006.JUNE,250
MANU, ACTUAL,CASH,USD, 2006.AUG, 400
Data in the application after the copy:
INPUT, ACTUAL,CASH, LC, 2006.JULY,200
INPUT, ACTUAL,CASH, USD, 2006.JULY,100
INPUT, ACTUAL,CASH, LC, 2006.MAY,200
INPUT, ACTUAL,CASH, USD, 2006.MAY,100
INPUT, ACTUAL, CASH, USD, 2006. AUG, 500
NO_IP, ACTUAL,CASH,LC, 2006.JULY,150
MANU, ACTUAL,CASH,LC, 2006.JUNE,250
MANU, ACTUAL,CASH,USD, 2006.AUG, 400
When set option = Replace and clear, this means CLEARDATA=1:
Example3:
Source selection: Time=2006.MAY, DataSrc = INPUT
Target selection: Time=2006.JULY, DataSrc = INPUT
Data in the application before the copy:
INPUT, ACTUAL,CASH, LC, 2006.MAY,200
INPUT, ACTUAL,CASH, USD, 2006.MAY,100
INPUT, ACTUAL,CASH, LC, 2006.JULY,300
INPUT, ACTUAL, CASH, USD, 2006. AUG, 500
NO_IP, ACTUAL,CASH,LC, 2006.JULY,150
MANU, ACTUAL,CASH,LC, 2006.JUNE,250
MANU, ACTUAL,CASH,USD, 2006.AUG, 400
Data in the application after the copy:
INPUT, ACTUAL,CASH, LC, 2006.JULY,200
INPUT, ACTUAL,CASH, USD, 2006.JULY,100
INPUT, ACTUAL,CASH, LC, 2006.MAY,200
INPUT, ACTUAL,CASH, USD, 2006.MAY,100
INPUT, ACTUAL, CASH, USD, 2006. AUG, 500
NO_IP, ACTUAL,CASH,LC, 2006.JULY,0
MANU, ACTUAL,CASH,LC, 2006.JUNE,250
MANU, ACTUAL,CASH,USD, 2006.AUG, 400
Any software coding and/or code lines / strings ("Code") included in this documentation are only examples and are not intended to be used in a productive system environment. The Code is only intended to better explain and visualize the syntax and phrasing rules of certain coding. SAP does not warrant the correctness and completeness of the Code given herein, and SAP shall not be liable for errors or damages caused by the usage of the Code, except if such damages were caused by SAP intentionally or by its gross negligence.