Skip to main content

Automation: New Record(s) based on # field

  • May 8, 2024
  • 3 replies
  • 21 views

Sean_Lake1
Forum|alt.badge.img+20

Hey all.

I'm looking to automate a task based on # of projects included in a record.

The above is a listing of test courses.  The are marked for the trigger conditions, and should be the only records that are created into the Project Production Table. 

I'd had a simple automation that did this perfectly.  However, I'm needing it modified to where it will now create new records based on the # of projects in that field:

Here's the automation setup:

I know I need it to loop a # of times based on that Project's field, but I just can't seem to figure it out in AT.

I feel my settings aren't quite there, obviously.  

Also, does the Trigger's conditions affect what records the FIND RECORDS action looks at or is it its own?

 

Thanks!

 

 

 

 

3 replies

Sistema_Aotearo
Forum|alt.badge.img+20

I'm not too familiar with scripting stuff but here are my thoughts how how it could possibly run a loop.

Make those Trigger conditions to include:

AND when "# of Projects/assets included" > "0"

Add a step that decrements the "# of Projects/assets included" field by 1.
Not sure how to do this, you might need a script.

Hopefully, that will re-trigger the automation until the number hits 0


TheTimeSavingCo
Forum|alt.badge.img+31

@Dan_Montoyacreated a pretty elegant solution for this and it boils down to:
1. In the table where you're creating the records, create a number field called "Current #"
2. In the table where you're creating the records, create a formula field called "Next #" where the formula is "{Current #} + 1"
3. In the table where you're creating the records, create a number field called "Desired #"
4. In the table where you're creating the records, create a formula field called "Create another" or something that checks whether "Current #" is equals to "Desired #"

For your initial create record automation, put the "Current #" value as "1", and put the "Desired #" value as "# of Projects/assets included?"

Create a new automation that will trigger whenever a record in the table where you're creating the records has a "Create another" value of "Yes" or some such, and its action would be to put the "Current #" value as the "Next #" value, and put the "Desired #" value into the "Desired #" field, does that make sense? 

I've probably butchered the explanation somewhat, and I would link you to the original thread but I've lost it, sorry!



Dan_Montoya
Forum|alt.badge.img+17
  • Employee
  • 275 replies
  • May 10, 2024

Thanks @TheTimeSavingCo , that was the base that creates more books for authors.