Concatenate two or more fields through transform map
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-10-2024 05:56 AM
Hello Community,
There is need to concatenate 4 fields from excel sheet into field "description" while doing the transform map. How can I achieve it through script.
Where Am I supposed to write the script?
The fields are
ISSUE_TYPE_NAME |
REPORTER |
LAST_EDITED_DATE |
CREATED_DATE |
2)Also, they have this field created date in excel sheet and they are looking to map it in RITM created date field. Question: - Is it possible to map created date into RITM create date?? My understanding is it is going to map system dates i.e the date at which the tickets are created not any other dates?
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-10-2024 06:13 AM
Hi @sajal_chatterje ,
In the transform mapping, check the Use source script and read all 4 variables, concatenate them and set to target field. Write some draft code and share if it didnt work for you.
-Thanks,
AshishKM
Please mark this response as correct and helpful if it helps you can mark more that one reply as accepted solution
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-10-2024 06:17 AM - edited 05-10-2024 06:18 AM
var field1 = source.field1.toString();
var field2 = source.field1.toString();
var field3 = source.field1.toString();
var field3 = source.field1.toString();
var concatFiled = field1 + ' ' + field2 + ' ' + field3 + ' ' + field4;
target.short_description = concatFiled ;
var description = source.issue_type_name + " - Reported by: " + source.reporter + "\nLast Edited Date: " + source.last_edited_date + "\nCreated Date: " + source.created_date;
target.description = description;
☑️ Please mark responses as HELPFUL or ACCEPT SOLUTION to assist future users in finding the right solution....