Failure: Related External ID: Cannot lookup a property on a null value, Reason: Value referenced in the sub-expression

Hi all,

I am trying to conduct an upsert operation on a child record in Salesforce.
I have defined the External ID for the record and the related object but keep receiving this message:

Failure: Related External ID: Cannot lookup a property on a null value, Reason: Value referenced in the sub-expression

The null-safe access has been checked in each of the mapper snaps.

@NAl Looks like even through you have defined external id, it is evaluating as null value from snap. Is that hardcoded value ? If not just double check your expression (=) is enable for external id field or not.

Hi there, the External Id isn’t hardcoded. In the output preview, there is a valid value

Can you post a screenshot of the expression, please?

sure,

It’s definitely that field that it’s complaining about, rather than the External-ID Field? (I’m not seeing any errors highlighted in that screenshot)

Screen Shot 2021-07-28 at 12.09.35 PM

@NAl Can you hardcoded the value and test, then we can understand the issue in salesforce or snap side.

@NAl,

I believe the Salesforce Upsert snap’s “External-ID Field” and “Related External ID” fields are expecting the actual field names - not the values from the fields. The values should be in your input payload - with matching key names.

Try unchecking the expression toggle “=” and removing the “$”. Or otherwise, uncheck the toggle and use the suggest feature.

image

Hi all,

I ended up creating a new version of the pipeline and that worked.