Transform Map question - Coalesce

MStritt
Tera Guru

We have a web service setup between our Account table and SFDC. In the transform map, we are coalescing on the Account Number on the Account field/value. If input coming from SFDC doesn't contain an Account Number, then it will not update any Account with the SFDC values (ignores the values). What were seeing, is that if the SFDC record does have an Account Number, but the Account doesn't exist, it's creating a new Account. Is there a way for the Transform map to check to see if the Account (Account Number) exists first. If it doesn't, then don't create a new Account and do nothing.

6 REPLIES 6

Yes, That's correct. It will ignore if record with coalesce is not found. If record is found that, then transform will happen.

palanikumar
Mega Sage

Hi,

You can create a transform script with "when = onBefore" with below script. This script will make sure new record is not createdd

(function runTransformScript(source, map, log, target /*undefined onStart*/ ) {

    if (action == 'insert') {
        ignore = true;
    }

})(source, map, log, target);
Thank you,
Palani