Edit key column

Not sure this was a thingโ€ฆ

So Iโ€™m trying to fix an issue with a bot using the Appsheet API. The API calls an action and the action creates a row in a table. Action type = set the values of some columns in this row.

The issue is I want to specifiy the key column within that action. Butโ€ฆ you canโ€™t. It seems once a key column is populated, it becomes Read Only, irrespective of any rules for that column. So if I add the key column to the action I get:

The column โ€˜ContactIDโ€™ of data action โ€˜TestAction3โ€™ cannot be modified.

Any ideas

0 9 336
9 REPLIES 9

Yes, always.

Iโ€™m not clear what youโ€™re trying to do. Why are you trying to edit the key value?


Thatโ€™s the wrong Action type for creating a row.

Hi @Marc_Dillon yeah I know. But I was trying to diagnose the issue with this from yesterday:

and then today I read this:

which says:

You can only invoke the following types of actions from the API:

  • Data: set the value of a column

  • Grouped: execute a sequence of actions
    All actions invoked in the grouped sequence must be either Data: set the value of a column or Grouped: execute a sequence of actions .

My origional action was a โ€œAdd a new row to another table using data form this rowโ€ so I created a โ€œset the values of some columns in this rowโ€ action to see if this was the culprit.

Iโ€™m very confused what your goal here is, sorry

If you still are having issues from the old thread, does it make more sense to continue posting there?

If youโ€™re trying to add a new record via API, maybe just use Add via API, not invoke an Action?


Yah, thatโ€™s news to me, but it makes sense for the most part.
Iโ€™m curious though, this article was certainly written before some of the newer Actions were created, like โ€œadd a new row with values from this rowโ€. Perhaps it was never updated. I would do tests to make sure you canโ€™t use that Action.

I just tested this for you.

Action type โ€œdata: add a new row to another tableโ€ successfully executed via an API invoke an Action call.

Action type โ€œexecute an action on a set of recordsโ€ does NOT work, returns error:

"Action of type 'REF_ACTION' for table 'parent' is not supported for the REST API."

@Steve, Could you update the doc linked above, to include the โ€œAdd a new rowโ€ Action type. Or, even better, find someone who knows more about this to properly/completely update this doc? Or I can submit a support ticket if thatโ€™s better.

Strange then that Iโ€™m not even seeing that error message

Sorry, the error wasnโ€™t returned via API response, it was in the Audit Log.

3X_3_6_36a728072de60bfcf883fcdab66761eefe1203e3.png

Edit to the above.

The โ€œexecuteโ€ Action that I tried to invoke, was just simply to run the same โ€œadd a new rowโ€ Action from before it, on the same Table.

I made a new โ€œgroupedโ€ Action, and just had it run the โ€œexecuteโ€ Action, and invoked it by the API, and it worked just fine.

i.e. API canโ€™t run an โ€œexecuteโ€ Action, but it can run a โ€œgroupedโ€ Action that in turn runs the โ€œexecuteโ€ Action.

So just wrapping it in a group action works?

Apparently.

Top Labels in this Space