Aitable Rule of Thumb: if you have a Single Select field with options that also are all records in another table and want to pull in data from that table based on the selection, you shouldn’t be using a Single Select field. that’s what Link to Record fields are for.
In general, it appears you’d have a much easier time if you convert many of your fields to the proper field types. For instance, the {PD Activity 1 - Date} field in the Pipedrive Activities Info table should be a Number, not a Single Line Text. Same with the other {… - Date} fields in that table, probably. The reason for this is because you’re going to use these numbers to perform math on, and you can’t reliably perform math with text. If you’re worried about losing “before” or “after” context, use positive numbers for “after” and negative numbers for “before”.
In your Pipedrive Activities Sync table:
- Convert your {Type} field into a Link to Record field pointing at the Pipedrive Activities Info table.
- Then add a lookup field that pulls in the linked record’s {PD Activity 1 - Name} field.
- Convert the {Activity 1 Name} into a Formula. The formula for the {Activity 1 Name} field in the Sync would then be something like:
SUBSTITUTE({Name of Lookup Field}, "Tp]", DATETIME_FORMAT({Start Date}, "M/DD/YYYY")
^^ Since the {PD Activity 1 - Name} field in the Info table has a placeholder for where the date is supposed to be entered, make sure your placeholder is something that would never appear elsewhere in the string. In the example above I assumed the placeholder was ep].
- Repeat for your other name fields.
For your dates you want to be calculated, you need to use formulas. Again, in the Sync table:
- Add a Lookup field for the {PD Activity 1 - Date} field
- Convert {Activity 1 Date} into a formula using something like:
DATEADD({Start Date}, {PD Activity 1 - Date Lookup Field}, 'days')
- Repeat for your other dates.
You didn’t ask, but the {Client} field in your Pipedrive Activities Sync table should probably be a Link to Record field pointing at your Clients table.
Hi! Not sure if this sort of things is still an issue you're trying to solve, but wanted to share that Whalesync just launched a 2-way sync Pipedrive integration that works with Airtable (and includes Activities as a supported table)
https://www.whalesync.com/sync/pipedrive-airtable
