Feb 06, 2019 10:49 PM
It seems that in order to remove all records from a linked field type during a patch/update, you have to always have at least one valid record id to include and keep linked. Otherwise, if try to update with an empty array (to clear the data out presumably) it gives an error that the record id is not valid.
Feb 06, 2019 11:50 PM
I may be wrong, but cannot delete this.
I think I had an externality causing this behavior.
Feb 07, 2019 12:24 PM
Hey @sull
Let me see if I can also recreate, because I’m current writing a tutorial on Airtable and linked records.
You want to unassign the records from the linked table but keep them in their original table correct?
Feb 15, 2019 10:03 AM
You can do this using a PATCH on the record, and set the linked field to null
. That will remove the links, but preserve the records in the other table.
For example, if record A has field “Links” which contains records B,C,D. I would issue a PATCH to record A with {"fields": {"Links": null}}
. After the operation completes, record A will no longer link to records B,C, and D, but the records still exist in their corresponding table.
Alternatively, you should be able to send an empty array. I just tested on one of my bases and it worked using {"fields": {"Links": []}}
Mar 31, 2019 06:43 PM
Yea I used an empty array but nice tip on the patch
Mar 31, 2019 06:44 PM
Thanks for the info, folks.
Apr 01, 2019 09:35 AM
yes, that is correct.