Help

Transfer attachments uploaded in forms

Topic Labels: Automations
Solved
Jump to Solution
2996 2
cancel
Showing results for 
Search instead for 
Did you mean: 
JazzHall
6 - Interface Innovator
6 - Interface Innovator

Hey everybody,

big Airtable fan here, we are managing a lot of processes for a concert venue with this awesome tool.

Now we’re stuck with the following problem:

  1. People send data (some text fields, some attachments) via a form. This information is written into it’s own table (let’s call it “updates”). It can happen, that several people send different data to the same fields, for each submitted form a record is created.
  2. From “updates” this data is transferred into our “main table” via Automation UPDATE RECORD on trigger WHEN RECORD IS CREATED. We’ve also built a way to always keep the existing submitted informations if more is submitted to the same field by another form submission. So far so good.
  3. Uploaded Attachments can be JPG / PDF or similar, those shall be saved to the “main table” as well in the equivalent field. Now it’s getting tricky.

As far as i have read it’s not possible to move the attachments from one table to another with an automation, so instead we are working with URLs. I found a formular, that creates the attachment URLs, the syntax will be something like “https://dl.airtable.com/.attachments/xxxxxxxxxx”.

When i try to send these values to our main table (UPDATE RECORD), airtable changes them to links with the following syntax: “https://cdn.filestackcontent.com/xxxxxxxxxxxxxxxx” - and these just don’t work. We always get a “file cannot be found” error.

The same applies, if we use the “URL” value of an attachment field in Automations. In Preview it shows a (working) “dl.airtable.com” link, after running you’ll find a “cdn.filestackcontent” link (not working).

Does anybody know, why these links are converted, if it can be prevented or if there are any other ways, that we get URLs or (even better) Files in Attachment fields unconverted to our main table without having to do something manually? This is really frustrating and i wouldn’t be writing here if i hadn’t tried anything, that came to my mind.

One idea was to not have the links in “updates” be interpreted as links, but as plain text - but i couldn’t manage that either.

Thanks in advance for any ideas or hints!

1 Solution

Accepted Solutions
JazzHall
6 - Interface Innovator
6 - Interface Innovator

Hey everyone,

i got help from airtable support directly regarding this issue and would like to share some insights here.

It seems, that it takes a little time to process the upload via filestack to airtable. That’s why an automation, that fires when a record is created (incl. attachments) is not suitable here. The process of uploading is not yet finished when it fires and the result is broken links.

There are (at least) two possbile solutions for this

Here is what Airtable support send me:

"Ultimately what we’re trying to do is delay the automation long enough for filestack to fully process the image. Once the attachment has been fully uploaded to our system, its URL should contain “dl.airtable.com”. We suggest that users utilize an automation that triggers when records have an attachment formula that contains “dl.airtable.com”.

How to achieve this:

  • Add a formula field to your table that outputs your attachment field, where the formula itself is the name of your attachment field, for example: {Attachment Field Name}
  • Add conditions to your automation (e.g., if using the [When a record matches conditions trigger] like shown below

Image_2022-03-10_13-22-26

I chose another solution, as i have multiple attachments which links should be send and i was not sure if they are done at the same time. So i delayed the automation by doing the following:

  1. Create a “Created time” field in your records. Make sure it contains time as well, not only date.
  2. Create a formular field with the following input:

DATETIME_DIFF(NOW(),{Name of your Created time field}, ‘minutes’)

Let the automation fire, when the formular field contains a certain number. I chose “3” (minutes) and that seems to be sufficient, i am now getting correct “dl.airtable.com” links.

Thanks to Airtable Support and maybe someday there is a simpler solution to this :slightly_smiling_face:

See Solution in Thread

2 Replies 2
JazzHall
6 - Interface Innovator
6 - Interface Innovator

Hey everyone,

i got help from airtable support directly regarding this issue and would like to share some insights here.

It seems, that it takes a little time to process the upload via filestack to airtable. That’s why an automation, that fires when a record is created (incl. attachments) is not suitable here. The process of uploading is not yet finished when it fires and the result is broken links.

There are (at least) two possbile solutions for this

Here is what Airtable support send me:

"Ultimately what we’re trying to do is delay the automation long enough for filestack to fully process the image. Once the attachment has been fully uploaded to our system, its URL should contain “dl.airtable.com”. We suggest that users utilize an automation that triggers when records have an attachment formula that contains “dl.airtable.com”.

How to achieve this:

  • Add a formula field to your table that outputs your attachment field, where the formula itself is the name of your attachment field, for example: {Attachment Field Name}
  • Add conditions to your automation (e.g., if using the [When a record matches conditions trigger] like shown below

Image_2022-03-10_13-22-26

I chose another solution, as i have multiple attachments which links should be send and i was not sure if they are done at the same time. So i delayed the automation by doing the following:

  1. Create a “Created time” field in your records. Make sure it contains time as well, not only date.
  2. Create a formular field with the following input:

DATETIME_DIFF(NOW(),{Name of your Created time field}, ‘minutes’)

Let the automation fire, when the formular field contains a certain number. I chose “3” (minutes) and that seems to be sufficient, i am now getting correct “dl.airtable.com” links.

Thanks to Airtable Support and maybe someday there is a simpler solution to this :slightly_smiling_face:

Two great workarounds! :grinning: :raised_hands: