Field [linked record] cannot accept the provided value, what is the error?

Not sure why I’m getting this error. Using an empty array works and removes the values. Essentially what I’m doing is, I’m matching companies to different events. I want to add the companies that are matched when found in the loop into my field called “Mail_Chimp_Company_LookUp”. This script is automatically updating all records every time an event is created. The results variable is an array of companies that are matched to the event tags.

In order to update a linked record field you must use the internal record ID (recXXXXXXXXXXXXXX). It looks like you are using the company name instead.

So, for all the company names in the results array, we need to use their internal record id as input for my lookup field? If I had for example,

Results = [Ebay, Amazon, FaceBook]
Need to get internal id of these records in the table I’m linking to, correct? So, this results in an array of internal recordId for each company name?

“Mail_Chimp_Company_Look”: [{id: [,,]}

I’m still getting the same error. It shouldn’t really matter what string value I pass into the look-up field, as long as it’s a string.

My query_2.records[j].id is rec1VgmTbsREkyHKP.

You need an array of objects, each with their own record ID. You are putting all the IDs in a single object. Notice that the object key is id and not ids. That is a clue that you need to include only one ID.

Try something like this …

“Mail_Chimp_Company_Look”: [

1 Like

Thank you for the clarification, it worked! I appreciate it! I didn’t notice it was an array of ids. I just assumed that after each comma separated value, it would be added to it.

1 Like

This topic was solved and automatically closed 3 days after the last reply. New replies are no longer allowed.