cancel
Showing results for 
Search instead for 
Did you mean: 

Is scripting possible on CPI-DS Mapping tab?

former_member805004
Discoverer
0 Kudos
725

Hi all,

Why do I get error in case of using script statement on Mapping tab in CPI-DS TargetQuery while the same function works well?

View Entire Topic
Parveen-Kumar
Product and Topic Expert
Product and Topic Expert

Hello Dmitrii

You can use the decode function in the mapping to write the ifthenelse logic. Refer to the following help document for more details.

https://help.sap.com/docs/SAP_CLOUD_PLATFORM_INTEGRATION_FOR_DATA_SERVICES/dab65b1584e04026a132a06a7...

decode ((EMPNO = 1), '111',

(EMPNO = 2), '222',

'NO_ID')

Thanks
Parveen Kumar

former_member805004
Discoverer
0 Kudos

Great! Thanks Parveen. This must work. I will definitely try it. Any idea on scripting use area? Does it cover dataflow processing out of pre- and postload scripts?

Parveen-Kumar
Product and Topic Expert
Product and Topic Expert
0 Kudos

Yes. you can write scripts in the Execution Properties at the task level, you can make edits in preload and postload scripts as needed to meet your business specifications. The scripts are generally called once and can be used to fill the global variables for the task.

https://help.sap.com/docs/SAP_CLOUD_PLATFORM_INTEGRATION_FOR_DATA_SERVICES/dab65b1584e04026a132a06a7...