Set column value w/no change causes action to...

Set column value w/no change causes action to abort?

I have a simple set of actions: (sequence (set column to “”), (set column to “Hi!”)). If the column is not already blank, the entire action completes. If the column is blank to begin with, the second set-column does not happen.

What’s going on?

+Steve Coile what is the conditional statement that you trigger that sequence of actions? AND/OR Have you tried setting a ISNOTBLANK([ColumnName]) to the condition of your 1st sequential action and ISBLANK([ColumnName]) to your 2nd sequential action?

@Levent_KULACOGLU sorry to be unclear. This is a Display prominently action triggered manually, not in a workflow.

@Levent_KULACOGLU I have not tried the conditionals. Are conditionals a requirement?

+Steve Coile I didn’t thought that it might be in a WF really. Conditions are not a requirement (as if you don’t set any condition, they are always assumed to be TRUE) but a good way of controlling your actions. Give it a try.

@Levent_KULACOGLU I appreciate the intent of your suggestion. The point of my post was not to find a way to avoid the outcome, but to ask why I’m getting this outcome. I would expect the entire action to work even if the first set-column produces no change.

+Steve Coile IMHO, what you’re asking for/your design intent is contrary to the nature of a sequential action. Provided the 1st step of the sequence is failing, then the remaining steps shall stop to prevent errata. Therefore I proposed use of appropriate/fitting conditional statements which will at least provide some sort of conditional branching.

@Levent_KULACOGLU I’m okay with that behaviour, if that is in fact the intent. I’ve not seen an action “failure” defined, nor AppSheet’s process for handling a failure documented.

I would not consider an identity assignment (x = x) to be an error under any circumstances, though I could imagine AppSheet interpreting the lack of change a failure. It’s an invalid assumption, but I can imagine the circumstance that might lead to that logic.

+Steve Coile I concur, but I belive the problem might be trying to set a null value/empty string to a column which is already blank

@Steve Is there any update to this?
I also need an action to be fired, even when it sets a blank value.
I need this, because this will do e recalculation of the row.

Also: If the value would stay the same, the action will not be fired.
Can’t we force it?

@praveen FYI

@Aleksi Do you have any idea how to force an action?

What do you actually want to do?

I read the whole post… so you want to force the action even when the column’s value has the same value you are trying to fill with your action. The reason is the same than when you try to save the same value when modifying the record. It won’t save that record either.

One way is if you add a timestamp action with NOW() into an additional column so it will have different value every time you trigger that action.

I have these Tables:

  • Houses - with addresses
  • Flats - related to the House
  • Things - related to the Flat AND the House
  • Images & Notes - related to the Thing AND the Flat AND the House.

Now I want to move the “Thing” from one flat to the other in the same house.
For that I created a slice of table “Things” that contains only the [Key] and the [Ref to Flat].
With an action I open the form to this slice and can change the [Ref to Flats]. (it’s a dropdown with all flats in that house).
In the Form view I set up: Event Actions: Form Saved: An Action that does a cascade change to the children. That means: In the Images and the Notes the [Ref to Flat] will be changed to the new flat.

But now I would like to move the “Thing” from one HOUSE to another HOUSE. Or even from one flat in one house to another flat in another house.
For that I added to the Slice also the [Ref to Houses].
With an action I open the form to this slice and can change the [Ref to House] AND [Ref to Flat]. (these are dropdowns with all houses and with all flats in the selected house).
In the Form view I set up: Event Actions: Form Saved: An Action that does a cascade change to the children. That means: In the Images and the Notes the [Ref to Flat] will be changed to the new flat.
The column [Ref to House] in the “Images” Table and the “Notes” table has a App Formula: [Ref to Flat].[Ref to House] (De-Reference), or if [Ref to Flat] isblank, then put in the House referenced to the Thing.
So by changing the [Ref to Flat], the [Ref to House] will be automatically changed.

This is working as long as I change the [Ref to Flat].
But some “Things” are not related to a flat, but only to a house. So I move it from one house to another house without selecting a flat.
After saving, the cascade action will not be fired, because [Ref to Flat] will stay blank.
I would like it to fire, because then the App Formula in [House] will be re-calculated and it will set the House referenced to the Thing.

I know I could “simply” do 2 Actions: One setting the [Ref to Flat], the other setting [Ref to House].
But I thought I could do it with just 1 Action.

1 Like

One question… why do you need all “additional” Refs for example in Images & Notes table? Do you just want to have virtual REF_ROWS so you could see all the Images and Notes tht belongs to that house for example in “Houses” table?

Yes. When I open the Detail view of a House, I want to see ALL Images and Notes. When I open a Flat I want to see the Images and Notes related to that Flat.

You could do the same with the virtual List/Select column without the ref. Then it would work without any actions… just change the Ref column’s option and sync… if I have understood your request correctly :slight_smile: