Help

Re: Attachments deleted but reappear in the database instead of the new ones

Solved
Jump to Solution
6349 1
cancel
Showing results for 
Search instead for 
Did you mean: 
Vianney
5 - Automation Enthusiast
5 - Automation Enthusiast

Hello everyone
I have a problem with the history of deleted attachments.

I have 2 fields "Attachments" (images): Field A and Field B
I have a Make scenario that generates the attachment of field B if the attachment of field A is filled in Airtable. The Field B attachment generated by Make is the same image as the Field A attachment to which the Make scenario adds a watermark and formats the name.
>> No problem

I have an Airtable automation that if the Field A attachment is deleted, then airtable deletes the Field B attachment.
>> No problem either

If I delete the existing attachment in field A and put a new attachment in field A (a new image), then first Airtable deletes the attachment in field B (thanks to the Airtable automation) but then in field B instead of having the new image corresponding to the new attachment in field A (sent by Make), Airtable puts the old image in field B.
In Make, I can see perfectly that the image sent to Airtable in Field B is the right one. No problem in the Make scenario. The problem is on the Airtable side.

Digging around in the Airtable forum, it seems to be due to the attachment history that is kept for the "History" function.
https://community.airtable.com/t5/automations/deleting-attachments-via-automation/td-p/67232
https://community.airtable.com/t5/other-questions/erase-all-attachments-from-the-attachment-field-in...
https://community.airtable.com/t5/development-apis/how-to-delete-previously-uploaded-attachments-cur...

I think Airtable is pulling up the attachment present in the history instead of showing the new attachment received from Make. What do you think about this? Would there be a way to remove the attachment history or do you see another solution?

Thanks for your suggestions

1 Solution

Accepted Solutions
Vianney
5 - Automation Enthusiast
5 - Automation Enthusiast

I found a solution: there was a conflict between the name of the image saved in the Airtable history and the new image generated by the Make scenario which was outputting the same name each time. Airtable displayed the first image with the same name. I added a random number at the end of my image name in the Make scenario and now I have my last image displayed.

See Solution in Thread

7 Replies 7
subinbabu
5 - Automation Enthusiast
5 - Automation Enthusiast

It sounds like the issue is with Airtable's attachment history feature. When you delete an attachment and then add a new one, Airtable may be pulling the previous attachment from the history instead of using the new attachment sent by Make.

Maybe these options will help you:

Solution 1: Remove the Record-level revision history.

Solution 2: Create a new field for the new image and use it to reference the new image uploaded by Make instead of replacing the old image in the same field.

Solution 3: Create a custom script that runs on a schedule to clear old attachments from the Airtable database.

In any case, it's always a good idea to test the different options and see what works best for you.

Thank you

Vianney
5 - Automation Enthusiast
5 - Automation Enthusiast

Thanks @subinbabu  for your help.

Regarding your solution #1, I can't find the "Keep a history of all versions of this field" option in the attachment field settings.

Vianney
5 - Automation Enthusiast
5 - Automation Enthusiast

I found a solution: there was a conflict between the name of the image saved in the Airtable history and the new image generated by the Make scenario which was outputting the same name each time. Airtable displayed the first image with the same name. I added a random number at the end of my image name in the Make scenario and now I have my last image displayed.


@subinbabu wrote:

Solution 1: Remove the attachment history. This can be done by going to the attachment field settings and disabling the "Keep a history of all versions of this field" option. However, doing this will delete all previous versions of the attachment and will not be reversible.

 Can you share more about this "Keep a history of all versions of this field" option? I believe that this feature is not available to all users. Are you part of an Enterprise plan that might have access to features that are not generally available? Are you at liberty to share more details of this feature, such as screen shots?

subinbabu
5 - Automation Enthusiast
5 - Automation Enthusiast

Sorry for the confusion, i mean "Record-level revision history".

subinbabu
5 - Automation Enthusiast
5 - Automation Enthusiast

Glad that you found a solution.

Sorry for the confusion, i mean "Record-level revision history".