Help

Calculate the difference between column A (created time date) and column B (csv of dates)?

2904 3
cancel
Showing results for 
Search instead for 
Did you mean: 
Andres_Hidalgo
5 - Automation Enthusiast
5 - Automation Enthusiast

So in my data column A is a created time date, column B has many lots, and column C has a birth date corresponding to each lot, so if column B is: 'LotA, LotB, LotC' then column C is, let's say, would be '03/28, 03/29, 03/30'.

How can I add another column containing the Age where I get the following values '2, 1, 0' which is the result of the difference between the created date and the birth date for each different lot?

3 Replies 3
Shannon_Bradley
7 - App Architect
7 - App Architect

I wonder if the information in one of my posts would be helpful? https://community.airtable.com/t5/formulas/date-formula-referring-to-2-feilds/td-p/39861 

Kenneth_Raghuna
7 - App Architect
7 - App Architect

You would need to create an automation that runs a script when a record is updated (or created depending on how the record is made).

It would need to split the dates in column C, then do the math for each one, then create an array of the results, and plug it into column D (Age).

As far as I know there is now simpler way to do it in Airtable.

Lom_Labs
7 - App Architect
7 - App Architect

Hello @Andres_Hidalgo , we've built an app that you may find helpful here.

The app will generate a script that you can add to your "Run a Script" automation action, and the script will  split the long text from multiple cells in the first table and create records in the second table, as well as linking the records together.

It does not matter how many data fields you have, so if you have the fields "IndividualAnchors1", "IndividualAnchors2", "IndividualAnchors3", "IndividualLink1", "IndividualLink2" for the same record, the app will still work fine.

Combine Fields and Create Records.gif

This will help you to create one record Lot with the date in another table.  You can then create a formula field to calculate the difference between the created date and birth date, and then use a rollup field to display the differences back in your original table!