How do I add a new row, then add that row as a reference (use it's new id) to another table?

I have two items - jobs and calendar events

They should be 1 to 1

jobs has a field/column called cal_event_ref.

Automation triggers when a new job is created.

II want it to create a new calendar event (synced to google calendar) whenever a new job is created. This calendar event then needs to be tagged onto the job in the field cal_event_ref.

I can’t for the life of me figure out how to make this work. I’d think you need to grab the id for the new cal_event, then paste it onto the job that triggered the automation to begin with.

How would I do that?

I ended up making 3 workflows.

1 for create (on job row added)

1 for delete (on job deleted)

1 for update (on row updated)

I couldnt figure out how to do the third one by just editing the calendar event, so I just delete it and add a new one again.

Yes, I also facing same issue. I if anyone can have any Idea please share. I want to make like that. this is very important.

For everyone’s future reference, there is a better way to do it now.

Use INPUT() function that’s in beta. See here: Using INPUT() to update another table using a valu… - Google Cloud Community

Summary:

You need 2 Actions.

1st Action -

2nd Action - On your Workflow

That’s for updating a row on Table 2 when a user has changed a row on Table 1.

You still need

  • a bot in the Automation for creating the row in the first place

  • and also one to delete any leftovers