I would like to be able to copy a field to the same object and choose to include some or all field options such as validation or conditional rules.
For example, I have an app that has a lot of fields (150+ in one Object) and most of these are very similar to other fields in the Object. It would have saved me countless hours if it was possible to select one or more fields and create duplicates of them. Ideally, the duplication would also copy conditional rules and apply them to the newly duplicated field and correctly reference the other newly duplicated fields as targets within the conditional rules.
In the Builder, in the relevant Object, in the Fields view, create a new button called "Actions", one of which is "Duplicate Fields".
The User clicks on "Duplicate Fields".
Checkboxes appear in the left-hand most part of the field boxes.
The User selects the fields they want to duplicate and clicks "Duplicate" button at the bottom of the screen.
A modal popup is displayed that gives the user some options about what to copy, for instance: a. Duplicate user data? b. Duplicate Conditional Rules? i. If Yes, are rules to be applied as absolute (keep referencing the original field) or relative (duplicate the fields and then reference the new fields in the conditional rules in the same manner as the original relationship)? c. How many times do you want to duplicate the fields?
The User enters their prefered settings and clicks the "Duplicate" button.
New fields are created with "Copy 1", "Copy 2", "Copy n" appended to the title of each.
Thanks for sharing @LindsayRob10468! Appreciate you taking the time to explain your problem and an idea for what a solution could look like. Curious if you could expand on the use case or a similar real world example for the app setup you’re describing?
I would caution against having such a large number of fields that have conditional rules, as there may be performance implications (see Managing Your App’s Performance - Knack Knowledge Base) but I am sure there are valid use cases that present issues we would want to explore solutions for.
Coming from Airtable, duplicating a field within a table was something that I did frequently, especially formula fields. If I was going to make a change to a formula field I would make a quick duplicate and test my changes there. This was one of the first things I felt was missing from Knack and was surprised it’s not there. Interesting to note that the column header popup alludes to this function. “Settings, Copy, &Delete”
It just occurred to me that there is currently a way to copy fields within an object!
We’ll see if we can expose this functionality in a more intuitive way - the tooltip you discovered @B11 certainly hints to the fact that this was planned at some point, and it’s an oversight that the text wasn’t updated. We’ll look into this from a full product update consideration.