Skip to main content
Solved

Run a script that sets single-select to pre-determined value


I have a button that I would like to trigger two tasks:

1 - trigger a webhook that passed the data to zapier (done)
2 - automatically update the value of a single select field to ‘true’

While the webhook script runs when I click the button, it seems that the other script I am using (to update the single-select) wants to take in a user input every time and it does not run automatically.

Is there a simple way to set the value of a single-select field automatically to true without me having to specific the field and the value every time with a script?

Best answer by Kamille_Parks11

Since you didn’t provide the script, here’s the most basic way to update a single select field:

await table.updateRecordAsync(recordID, {
  "Single Select Field": {name: "true"}
})
View original
Did this topic help you find an answer to your question?

3 replies

Kamille_Parks11
Forum|alt.badge.img+25

Since you didn’t provide the script, here’s the most basic way to update a single select field:

await table.updateRecordAsync(recordID, {
  "Single Select Field": {name: "true"}
})

  • Author
  • New Participant
  • 1 reply
  • July 16, 2022
Kamille_Parks11 wrote:

Since you didn’t provide the script, here’s the most basic way to update a single select field:

await table.updateRecordAsync(recordID, {
  "Single Select Field": {name: "true"}
})

Thank you @Kamille_Parks! That worked!


Forum|alt.badge.img+3
  • Participating Frequently
  • 8 replies
  • November 23, 2023
Kamille_Parks11 wrote:

Since you didn’t provide the script, here’s the most basic way to update a single select field:

await table.updateRecordAsync(recordID, {
  "Single Select Field": {name: "true"}
})

how can i do this with data from input.config?

i am running into issues with setting the single select from data input from a webhook. 

        'Work Status': name: webhookData['Work Status'],
 
webhookData is my input.config name. 

Reply