How to Prevent duplicate records through transform map?

reddy8055
Tera Contributor

Hi,

I am trying to load data from Aternity to Software usage table using transform map. When I tried to load the data to software usage table there are duplicate records with same user name, publisher, product and last used date. How can I prevent this? I cannot put colease as there is no unique field to define.

find_real_file.png

 

Thanks,

2 REPLIES 2

Community Alums
Not applicable

You can put 'colease' on all the fields ie user name, publisher, product and last used date. 

When you put colease on multiple fields, serviceNow will insert only if the column combination is different from an existing record, other wise serviceNow identify the record by column combination and update the corresponding record.   

Tony Chatfield1
Kilo Patron

Hi, in your transform you will need to set coalesce to true for the field combination that makes the record unique IE 'user name, publisher, product and last used date'

If these values are not available directly from your data you can use a 'field map' source script to derive suitable value for the field(s)

Create a field map (servicenow.com)

or you can utilize a before transform script to process each row in your record set and decide to insert\update\abort as required.

Transform Event Scripts | ServiceNow Developers