Update counter when action is triggered - problem when duplicating

I’ve been trying to figure out a way to count records and increment the number in a field and found this great solution by @Kamille_Parks which does the trick. But I’ve run into a couple of issues which I’m hoping someone can help me with. In my case I’m tracking change orders related to a job and would like to make each new change order n+1, relative to the job. So my Change Orders are Job#-1, Job#-2,Job#-3,. This solution does what I’m looking for but breaks if the user duplicates the record, which we’d like to do. The trigger here looks for a blank value for the count # but if you duplicate then the count field value is not blank, so the trigger fails. I’ve tried a bunch of things but haven’t figured it out. Any suggestions out there? It doesn’t seem possible to test to see if one field is = to another field, which could have possibly helped here.

If your base is in a Pro workspace you can set the fake Autonumber field to have its permissions so no one can edit except Automations:

This way when you duplicate the record, the new record comes in with no field value.

You could do that with a formula field:

IF({Field A} = {Field B}, "yes", "no")

Then have your automation filter for conditions where the formula outputs “yes”.


Amazing. The field permissions did the trick. Thank you so much. I also see how to do a test now.

1 Like

Genius. Never would have thought of that :exploding_head:

1 Like

This topic was solved and automatically closed 3 days after the last reply. New replies are no longer allowed.