The CreatorCon Call for Content is officially open! Get started here.

State of Update in Transform script

Daryll Conway
Giga Guru

I'm running an onBefore script on a transform map and I need to set the Import set Row state to update.

I'm aware of the ignore = true setting but I can't find a way to set this to 'update'.

Is this possible?

15 REPLIES 15

poyntzj
Kilo Sage

Hi Daryll


Setting a coalese field should work


How would I go about doing that?


I guess it does depend on what is being imported, but if you are aware of a field (or set of fields) that make each row unique, in your transform maps, you look at the fields and make which ever field(s) mark the record as unique as True under the coalese field.



For us when we import our users from their sources (LDAP feeds or a CSV from an iSeries), we coalese on the user_name as it is unique



When we create a web service - so say one on Incident, We ask the 3rd party to provide their reference number (or we get it when we inject a new ticket into their system).   We store this field in the correlation_id field.   We have this marked as a coalese field.   If the 3rd party send in a SOAP message and there is a matching reference / coalese field it updates the existing ticket, otherwise it creates a new one.




find_real_file.png



find_real_file.png


We have an unusual setup which is why I need to go about this in a different manner.



The issue we have is that we don't have a consistent field we can coalese on.


If we have a sys_id passed in we check against existing records and update using a glide record call in the transform onBefore Script. If it doesn't have a sys_id   one is created in the transform and a new record created.



This problem arouse after we updated to Dublin patch 7, before this we had a sys_id field that was always used but since the update this was removed as it was causing problems which stopped the import being processed.



I have everything working in SN it's just the response that goes back to the integrated product that is the issue.



So ideally I just need to change the import set row state to updated via script so that the response is correct.