Skip to main content
Solved

Scripting problem

  • May 22, 2024
  • 1 reply
  • 16 views

Forum|alt.badge.img+3

I have a problem with a script that worked and all of a sudden, stopped to work:

"App Name" is a linked record field. "Add App On Sign Up" is another linked record field. When a value is inserted in "Add App On Sign Up", I need this value to be inserted in "App Name" (inserted, meaning adding a value, not replacing a value to "App Name".

Anyone has a better script to propose?

The error message is:

Error: Field "fldGBiazYCpFzbsOv" cannot accept the provided value.
    at main on line 12

Field "fldGBiazYCpFzbsOv" is the field id of App Name

 

 

 

const table = base.getTable("Members"); const query = await table.selectRecordsAsync(); for (const record of query.records) { const appNames = record.getCellValue("App Name"); const addAppOnSignUp = record.getCellValue("Add App On Sign Up"); if (appNames && addAppOnSignUp) { const updatedAppNames = appNames.map(appName => appName).concat(addAppOnSignUp); await table.updateRecordAsync(record, { "App Name": updatedAppNames }); } }

 

 

 

 

Best answer by Matthieu_Chatea

I solved it by changing the script to perform an update in the Apps table and not directly in the Members table

1 reply

Forum|alt.badge.img+3
  • Author
  • New Participant
  • 2 replies
  • Answer
  • May 23, 2024

I solved it by changing the script to perform an update in the Apps table and not directly in the Members table