Transform Maps

yoli1
Tera Contributor

Hello everyone, In a Transform Map I want a field in the target table to remain empty. Should I achieve this by using a script like answer=""; or is it sufficient to simply not include the field in the Transform Map?

3 REPLIES 3

Raghu3
Tera Contributor

To make this decision, you need to think about two scenario.

 

1) If you want that field empty when the record found in data source then you should add field in transform map so whenever record is found it will make that field empty.

2) If you are just seeking to make this field empty whenever inserting record then it's better not include the field in transform map data mapping.

varaprasad123
Kilo Guru

Do not map the field at all in the Transform Map configuration, and it will remain empty during the transformation process.

jaheerhattiwale
Mega Sage
Mega Sage

@yoli1 If it needs to be empty all the time when transform map runs then do not create the field map for that.

 

If the target field value is conditional then add the field map with script like below

if(condition){

answer = "";

}else{

answer = "SOMETHING HERE"

 

Please mark the answer as correct or helpful based on impact
ServiceNow Community Rising Star, Class of 2023