Hello, Here is some background so you can clearly understand the ask:
My app has an action to create a duplicate project, and it open a new form and allows the user to edit the new project details, such as the name and location, and save it. So essentially it's just transferring the same information into a new row in the Projects database table with a new Project #.
A project also has a Ref list of Scope of Work, which has its own status and description saved in it's own table. However, I would like this to "copy" over as well. But I realize it must create a copy set of unique scope of works in the table, that somehow must Reference/Relates to the the new project # as well.
I have figured out how to make an action 1) to first Select the Scope of Work related to the original project.
2) A Referenced Action to Copy the content of each Scope of Work BUT the missing link is How do I get and set the new Project #?
Maybe a bot that works after an Add Only update for a new Project that has a value in a new column called "Copied From" and if that exists, then to somehow select the scope of work from the original project # and runs a sequence of actions to create copies?... Brainstorming
Thank you in advanced for lending your brain power and expertise.
One way I have done to get the key value of a newly created row is to use a formula like
MAXROW("your table","_RowNumber")
You can set this expression to the value of the related project column in your Bulk Copy SoW.
This assumes that there are no additional rows created between the time you create a new project and the time you perform the bulk copy and the app is synced. I believe this is very unlikely if everything is performed as part of grouped actions.
Your case is quite common and you might want to do a search on "copy parent and child" for more tips.
User | Count |
---|---|
16 | |
7 | |
6 | |
5 | |
3 |