I get an enumeration error when trying to do an action on add from a workflow but when I click the action in a view it works fine? The action adds a row to a table.
Please post a screenshot of the error.
![]()
Oh man so small
_RowNumber is your key?! Oh, Austin⌠Yer killing me, man!
Itâd help to see the action configuration. Iâd guess youâre trying to set an Enum or EnumList column value to a value that isnât a defined value and the column doesnât allow other values.
@Steve
I think Reports could be having issues. I have actions that work perfectly when used from a view or called from a workflow but fail when run from a report. Note the similarities in error messages:
âErrorsâ: "Error: âExecute a Sequence of Actionsâ Grouped action âComboCopyDonorRequestsSetAddedâ child action âCopyDonorToRequestsâ failed due to error: Error: Perform DataAction âCopyDonorToRequestsâ failed because Row having key â22b2f18eâ in table âRequestsâ in field âSTART_DATEâ is required to have a value. \nError: âAdd Rowâ Data action âCopyDonorToRequestsâ failed with exception Collection was modified; enumeration operation may not execute. .",
I have a post about it with screen shots of my actions.
[Combo action works from deck view but not in a workflow](https://community.appsheet.com/t/combo-action-works-from-deck-view-but-not-in-a-workflow/32503) Questions
I am copying rows from one spreadsheet to another through my app. Basically importing them and adding the column values as needed. This works as an action on a view. I use it in a combined action, image #3. [Screen Shot 2020-10-15 at 2.34.34 PM] This works as well. I use it in a combined action, image #3. [Screen Shot 2020-10-15 at 2.34.49 PM] This is the combined action. Works perfectly from a deck view. But it wonât work when called from a Report. [Screen Shot 2020-10-15 at 2.35.05 PMâŚ
Dont insult me like that
I have a proper key and its being set manually in the action and has an initial value.
Milestone and Initiative are References to Projects, and Project_Milestones.
Status is an Enum.
Hi @Austin_Lambeth
I dont see your key column in there?
Austin_Lambeth:
I have a proper key and its being set manually in the action and has an initial value.
So hereâs the thing Iâve noticed with Data: add a row to another table using values from this row: the Initial value expression for the key column value for the new row is evaluated before the columns set by the action are given their values, so the key columnâs Initial value expression does not have access to those new values. Would this affect your action?
Well it was originally using the initial value and it was not setting the key from the action. This action is being triggered by an ON ADD workflow. Would that make a difference too? Its referencing the added milestone through Milestone_ID. Is this a chicken and the egg? The milestone doesnât exist before Iâm trying to set the reference to the milestone?
The enumeration error on rownumber is a very odd one. My Initial Value is MAX(Project_Details[Detail_Key])+RANDBETWEEN(1,500) so is it trying to grab a value based on itself?
I noticed that too. I guess my co-developer was in the app when I made that change but I tested it this morning with it in there for sure and it still errored the same.
Austin_Lambeth:
This action is being triggered by an ON ADD workflow. Would that make a difference too?
Workflows run after the added/updated/deleted row has been added/updated/deleted.
Austin_Lambeth:
Its referencing the added milestone through Milestone_ID. Is this a chicken and the egg? The milestone doesnât exist before Iâm trying to set the reference to the milestone?> The enumeration error on rownumber is a very odd one. My Initial Value is MAX(Project_Details[Detail_Key])+RANDBETWEEN(1,500) so is it trying to grab a value based on itself?
Iâm completely confused by this.
So [milestone_ID]=[Milestone_ID]
I think your previous answer disproves this but I was wondering if the Milestone_ID was not valid because it didnât exist yet.
The second part is me asking about the enumeration error cause its around the rownumber field which has no user control so its very weird that it is erroring.
My last statement confuses me too. Its early
For now my solution as is becoming more often than not is, avoid appsheets method and go to a database trigger

