Triggering Workflow

I want to trigger a workflow whenever a new row OR whenever an update is made to any of the columns except ‘[Generate PDF]’ column.
Can anyone suggest me a solution please?

Hi,

I think you will need to spell out all of the other columns in an OR() statement, and as well, use the Appsheet before/after feature. So some psuedo expression might look like:

OR(
[_THISROW_BEFORE].[Field1] <> [_THISROW_AFTER].[Field1],
[_THISROW_BEFORE].[Field2] <> [_THISROW_AFTER].[Field2],
[_THISROW_BEFORE].[Field3] <> [_THISROW_AFTER].[Field3]
)

And then mark the workflow itself for “adds and updates”. Can you give that a try? (I may have missed something here)

1 Like

Thanks @TyAlevizos. I had this in my mind but I would like to have an expression that only takes the ‘Generate PDF’ as an input.
(i.e. columns that are to be excluded)
It must be computationally less expensive.

Would this work? workflow set to “adds and updates”

NOT( [_THISROW_BEFORE].[Generate PDF] <> [_THISROW_AFTER].[Generate PDF] )

This is all very subtle and I would need to spend some time testing it (which alas I do not have time for today)

??

thanks. but this does not work.
Interestingly, the first method does not work either.

Can anyone suggest me an expression to exclude some of the columns from triggering the workflow. I am short of time please. I have used the following but it does not work.

AND
(
(OR(
[_THISROW_BEFORE].[Owner’s Name]<>[_THISROW_AFTER].[Owner’s Name],
[_THISROW_BEFORE].[Owner’s Phone]<>[_THISROW_BEFORE].[Owner’s Phone],
[_THISROW_BEFORE].[Owner’s Status]<>[_THISROW_BEFORE].[Owner’s Status],
[_THISROW_BEFORE].[Add Image ?]<>[_THISROW_BEFORE].[Add Image ?],
[_THISROW_BEFORE].[Image]<>[_THISROW_BEFORE].[Image],
[_THISROW_BEFORE].[Category]<>[_THISROW_BEFORE].[Category],
[_THISROW_BEFORE].[Plot Allocation]<>[_THISROW_BEFORE].[Plot Allocation],
[_THISROW_BEFORE].[Project Name]<>[_THISROW_BEFORE].[Project Name],
[_THISROW_BEFORE].[Floor]<>[_THISROW_BEFORE].[Floor],
[_THISROW_BEFORE].[Unit No.]<>[_THISROW_BEFORE].[Unit No.],
[_THISROW_BEFORE].[Rate Per Square Foot]<>[_THISROW_BEFORE].[Rate Per Square Foot],
[_THISROW_BEFORE].[Block]<>[_THISROW_BEFORE].[Block],
[_THISROW_BEFORE].[Sector]<>[_THISROW_BEFORE].[Sector],
[_THISROW_BEFORE].[Street No./Road]<>[_THISROW_BEFORE].[Street No./Road],
[_THISROW_BEFORE].[Block]<>[_THISROW_BEFORE].[Block],
[_THISROW_BEFORE].[Plot No.]<>[_THISROW_BEFORE].[Plot No.],
[_THISROW_BEFORE].[Other Details(If Any):]<>[_THISROW_BEFORE].[Other Details(If Any):],
[_THISROW_BEFORE].[City]<>[_THISROW_BEFORE].[City],
[_THISROW_BEFORE].[Society/Location]<>[_THISROW_BEFORE].[Society/Location],[_THISROW_BEFORE].[Size (Unit)]<>[_THISROW_BEFORE].[Size (Unit)],
[_THISROW_BEFORE].[Size (Number)]<>[_THISROW_BEFORE].[Size (Number)],
[_THISROW_BEFORE].[Dimension (Length x Width: 25 x 50)]<>[_THISROW_BEFORE].[Dimension (Length x Width: 25 x 50)],
[_THISROW_BEFORE].[Total Price (In Numbers)]<>[_THISROW_BEFORE].[Total Price (In Numbers)],
[_THISROW_BEFORE].[Amount Paid]<>[_THISROW_BEFORE].[Amount Paid],
[_THISROW_BEFORE].[Profit Demanded]<>[_THISROW_BEFORE].[Profit Demanded],
[_THISROW_BEFORE].[Discount Applicable]<>[_THISROW_BEFORE].[Discount Applicable],
[_THISROW_BEFORE].[Discount in Rupees]<>[_THISROW_BEFORE].[Discount in Rupees],
[_THISROW_BEFORE].[Transfer Fee]<>[_THISROW_BEFORE].[Transfer Fee],
[_THISROW_BEFORE].[Membership Fee]<>[_THISROW_BEFORE].[Membership Fee],
[_THISROW_BEFORE].[Taxes]<>[_THISROW_BEFORE].[Taxes],
[_THISROW_BEFORE].[Possesionable]<>[_THISROW_BEFORE].[Possesionable],
[_THISROW_BEFORE].[Payment Status]<>[_THISROW_BEFORE].[Payment Status],
[_THISROW_BEFORE].[Installment Amount]<>[_THISROW_BEFORE].[Installment Amount],
[_THISROW_BEFORE].[Due Amount Before Transfer (Pending Installments for SOD Clearance)]<>[_THISROW_BEFORE].[Due Amount Before Transfer (Pending Installments for SOD Clearance)]
)),
([Post Ad]=“Yes”),
(ISNOTBLANK([Ad Type]))
)

Screenshot:

But if I update any of the columns which I have not specified inside the OR() expression, the workflow still triggers.
@Steve @TyAlevizos

Add a column of type ChangeTimestamp and set Columns to include all columns to which changes should trigger the workflow (i.e., all except Generate PDF). In your workflow Condition expression, use [_THISROW_BEFORE] and [_THISROW_AFTER] to check for a change in that ChangeTiimestamp column.

3 Likes

this is awesome @Steve I completely forgot about this column type. Muhammad can you try this? Here’s the details of this column type:

I would also gently and with respect like to point out that the community forum is clearly not a place to post time-sensitive questions. By its very nature, it’s an asynchronous threaded messaging platform designed to track communications over long periods of time. Thank you!

3 Likes

@Steve I have just tried what you recommended. But still facing same problem.


Generate PDF = Yes (in the image below)

Updated the ‘Generate PDF’ column:
‘Generate PDF’ column = No (in the image below)

Workflow Triggered and therefore email received: (in the image below)

Workflow:

thanks @TyAlevizos.
All right, I understood your point about time sensitivity.

Any other option to solve this issue? @Steve @TyAlevizos

I did notice that the workflow also has to catch for not(isblank()) on the ChangeTimestamp field . I am not sure why. That doesn’t make sense to me. So, my final workflow condition looks like this:

and(
[_THISROW_BEFORE].[ChangeTime] <> [_THISROW_AFTER].[ChangeTime],
not(isblank([ChangeTime]))
)

Here is a working example that I put together. Hope this helps!

2 Likes

thanks for your suggestion.

You might want to have a look at this as well.

1 Like

thank you so much @TyAlevizos . It solved my problem, finally. Really appreciate and acknowledge your effort and time spent.
Thanks @Steve

1 Like