Do i need Parabola or zapier for this ? Match making

Hello,
I am building a matc hmaking app for jobs (offers and requests).
I have two tables : first for job offers and second for profils
in both tables i use many fields but 4 have same options (multi select).
I would like to match those two tables based on the 4th fields, if all have same options then start an automation like email.

Do i need an extrenat tool like parabola or it can be done inside airtable with linked tables for example ? How i can include data from a linked table automatically ?

Thanks a lot for your advicess :slight_smile:

You could try this with an Automation involving a Script. Trigger the automation on the creation of a new record in one of your tables. The first step will be a script, and your script will need two inputs:

  • Name: options, Value: [Record (Step 1 Trigger) … MultiSelectField … List of ‘name’]
  • Name: triggerRecordId, Value: [Record (Step 1 Trigger) … Record ID]

The script would look like this:

const inputConfig = input.config()

const options = inputConfig.options.split(", ").sort()
const triggerRecordId = inputConfig.triggerRecordId

const triggerTable = base.getTable("Table 1")
const oppositeTable = base.getTable("Table 2")

const oppositeQ = await oppositeTable.selectRecordsAsync()
const oppositeR = oppositeQ.records

const matches = new Set()

oppositeR.forEach(x=> {
    const checkOptions = x.getCellValueAsString("Multiselect Field Name").split(", ").sort()

    if(options.length === checkOptions.length) {
        let isMatch = true
        for (var i = 0; i < options.length; i++) {
            if (options[i] !== checkOptions[i]) {
                isMatch = false
            }
        }
        isMatch && matches.add(x.id)
    }
})

const combinedMatches = Array(...matches)

combinedMatches.length && triggerTable.updateRecordAsync(triggerRecordId, {
    "Link": combinedMatches.map(x => ({id: x}))
})

const matchesEmails = combinedMatches.length ? combinedMatches.map(x => {
    return oppositeQ.getRecord(x).getCellValue("Email")
}) : null

output.set("matchesEmails", matchesEmails)

The above script checks the values for the multiselect field against the values of the “same” multiselect field in the other table. If the values match, the script finds that matching record’s associated email.

From there your next step could send an email using the output from the script: matchesEmails

1 Like

Thank you very match,
I am realy beginner on airtable and scripting is an einstein lever for me,
I think i ll go to zapier …