Tap Forms – Organizer Database App for Mac, iPhone, and iPad › Forums › Using Tap Forms › Many-to-Many field of an original record cleared after record duplication
- This topic has 9 replies, 2 voices, and was last updated 10 years, 9 months ago by Alexander Lin.
-
AuthorPosts
-
March 11, 2014 at 8:19 PM #9347
Alexander LinParticipantHi,
I am building up a Many-to-Many relationship for Product/Parts forms
One Link-to-Form of each Product records links to many Parts recordsDue to Most of Parts are common to all Products, and each Product contains 10-20 Parts in general.
I try to duplicate a new Product record from an existed Product record and modify it.
Duplicated record looks fine, but the Link-to-Form field to Parts of original record is cleared.I need someone’s advise to get rid of this problem since it did take a lots of time to recover the original links after I duplicated new records,
many thanks.
AL
March 11, 2014 at 9:55 PM #9352
BrendanKeymasterHello Alexander,
Link to Form fields aren’t duplicated when you use the Duplicate Record command.
So that’s the problem you’re having.
I don’t duplicate linked fields because I couldn’t decide where it should stop duplicating. But I guess it would be reasonable for many-to-many links to just point the linked records at the new duplicated record.
I’ll see what I can do for a future update. I can’t say exactly when though.
Thanks!
Brendan
March 12, 2014 at 7:52 AM #9364
Alexander LinParticipantHi, Brendan,
Thanks for your kindly response.
I think I’d better to show a case to describe the problem I encountered.
I create a new simplified test case on iOS environment
Two forms named “Products” and “Parts” configured that based on what I am going to use.Parts form configured with only 1 field. One text field named “Part ID”
Product form contains 2 fields, one text “Product ID” field and the other a Link-to-Form “Part ID” field for linking to Parts form with inverse relationship switch enabled (and a Link-from-Form generated on Parts form)First, I add 4 records say “Part a”, “Part b”, “Part c” and “Part d” in Parts form
Then, I create “Prod 1” with Link-to-Form “Part ID” field selecting “Part a”, “Part b” and “Part c”
Next I duplicate “Prod 1” by using ‘Duplicate Record command’ to create a new record “Prod 2”.And the result I saw, “Prod 2” contains 3 links at “Part ID” field. But the links at “Part ID” of the original record “prod 1” is cleared.
I think it is reasonable Prod 1’s links data shall be remained while Prod 1’s links data duplicating to Prod 2
Hope this could make it more clear.
Thanks
AL
March 13, 2014 at 3:03 AM #9373
BrendanKeymasterHello Alexander,
If you send me your form template I can try to duplicate the problem you’re seeing. I’ve tested the code to duplicate a record on the Mac version (the underlying code to do the duplication is the same between iOS and Mac), and it did not duplicate the linked records or move them to the duplicated record. Maybe the issue is that Tap Forms selected the wrong record after it duplicated. If it’s a duplicate record, it’s difficult to tell which is the right one. Tap Forms should be selecting the new record though.
Thanks,
Brendan
March 13, 2014 at 10:00 AM #9385
Alexander LinParticipantHi, Brendan, thanks.
I exported template and data of Products and Parts forms separately, and email to support@tapforms.com
Totally four emails sent, one email for each exported file ( .tff and .csv )
March 13, 2014 at 9:08 PM #9393
BrendanKeymasterThanks Alexander. I’ll give them a look.
March 13, 2014 at 9:10 PM #9394
BrendanKeymasterAlso, you said this was on iOS. Were you working with the iPhone or iPad version?
March 14, 2014 at 12:19 AM #9398
Alexander LinParticipantHi, Brendan, thanks.
Yes, it was working with both iPad and iPhone.
Originally I encountered this problem when with iPhone.
And I beam it to iPad version for verification.
The result is same.Version is iOS 7.0.6
Thanks
AL
March 14, 2014 at 12:16 PM #9400
BrendanKeymasterHello Alexander,
Ok, I think I’ve found the problem. The issue is that Tap Forms was not showing you the duplicated record. It was still showing you the original record. So your duplicated record was a different record than the one you were currently viewing. Tap Forms was not removing the linked records from the original record. I’ve fixed this for the next update. I’ll also make sure that Tap Forms adds new linked records for any many-to-many Link to Form fields. I can’t do it for one-to-many because that would require moving the linked records to the duplicate record, which I don’t think is what should happen.
Thanks!
Brendan
March 15, 2014 at 3:16 AM #9403
Alexander LinParticipantHi, Brendan,
Thanks for your efforts to figure out this problem.
Duplicate linked records for only Many-to-Many Link to Form fields is fine.
It is good enough for me to support what I am going to use.Many thanks.
AL
-
AuthorPosts
You must be logged in to reply to this topic.