Tap Forms – Organizer Database App for Mac, iPhone, and iPad › Forums › Using Tap Forms › Linked Forms: One to Many Inverse Relationship
- This topic has 14 replies, 5 voices, and was last updated 8 years, 5 months ago by Joshua Soule.
-
AuthorPosts
-
May 3, 2014 at 6:20 PM #9982
1LeviteParticipantIn learning the features of TF, I’ve observed a difference between how the Inverse Relationship on the Child form appears depending on whether the Parent Link to Form was defined as One to Many or Many to Many. (OSX version)
I searched the Forum for similar postings, and didn’t find any specifically for this issue. Apologies if I missed one.
I’ve attached a very simple Form screenshot from a Child Form to show the differences I observed.
CASE 1: When the Parent form Links as One to Many, the Inverse Relationship on the Child form (Link from Form) appears as a simple entry of 1 to 5 rows of data, depending on the selection of List View Fields in the Parent Form properties.
CASE 2: When the Parent form links as Many to Many, the Inverse Relationship on the Child form appears as a table, where all desired fields for each parent record selected may be viewed by organizing the table columns.
The One to Many Inverse Relationship on the Child Form doesn’t seem to represent photos or checkboxes in the same way as the MtM table. For example in Case 1, the checkbox appears as “Yes”, not a graphic checkbox as it does in Case 2.
So….
1) I’d really like to have the One to Many Inverse Relationship (Link from Form) on the Child shown somewhat like the MtM Table. This isn’t a deal breaker for me, since my workaround would be to define the link as a Many to Many. But it would be nice to see the full parent record in the Link from From field.
2) If I’m missing something in initializing the fields, please set me straight.This is a great product–I’m just slow to initialize it. I want to get the forms set up right before I make the final import of my data tables and sync up to OS7. Any & all advice is welcomed.
May 3, 2014 at 6:32 PM #9986
1LeviteParticipantI guess I didn’t know how to attach graphics correctly. Here’s the screen shot
Attachments:
You must be logged in to view attached files.May 3, 2014 at 7:08 PM #9991
BrendanKeymasterHi 1Levite,
1. The inverse of a one-to-many is a many-to-one. So on the child form, to view the parent record, Tap Forms displays just a single record. It uses the identical format to display the record as you see in the records list view on the left in your screenshot. It wouldn’t really make sense to display it as a table view if there’s only one record to display. At least that was my thinking when I built that code.
2. Nope, looks like you’re doing everything right.
Thanks!
Brendan
May 5, 2014 at 7:11 PM #10029
1LeviteParticipantThanks for the snappy response.
Agreed a one-row-table doesn’t make much of a table.
I’ll fiddle around with the List View order to see if I can make use of one-to-many more effectively.
May 27, 2014 at 7:25 PM #10255
Frank TikketParticipantBrenden put a cool thing on the right side (mac) that looks like some small scissors… click that and you can select and deselect which columns you want displayed in your many-to-many table on the child forms (or parent forms).
Brendan, on the many-to-many selection in the child form (the link from), i can’t get it to display a name in the IOS version… just a link to the parent form (no name for the link). On the table view (mac) i can’t see any name at all on either one-to-many or many-to-many for that column. Its just blank, the record itself shows data but the table view shows nothing?
May 28, 2014 at 7:12 PM #10286
1LeviteParticipantSorry to bring this up again, but Eduardo’s post regarding identical link-to-form field showing two ways made me revisit some of the test forms I made up as I was learning TF. BTW: Mac OSX 10.8.5 TF 2.2.2.
The observation: The One-to-Many inverse relationship field can appear as a table; the Many-to-Many inverse relationship field can appear as a single entry. You just have to be very indecisive about your selection of Link Type–but so far I’d advise against it.
The method: I had to try this a couple times from scratch to make sure I wasn’t making a mistake. I was able to reproduce this a couple times.
1. Assume FORM 1 is a PARENT. Create a Many-to-Many field, linked to FORM 2 (CHILD), Inverse Relationship.
2. Go to FORM 2 and you’ll see a table for the “Link-From-Form”. The multiple record selection works as expected.
3. Return to EDIT FORM 1 Many-to-Many field, and do nothing except to click the radio button for One-to-Many. DONE.
4. Go to FORM 2 and the table remains, except it behaves as a one-to-many inverse, allowing selection of one record.Similarly….
A. Assume FORM 1 is a PARENT. This time create a One-to-Many field, linked to FORM 2, Inverse relationship.
B. Go to FORM 2 and you’ll see a single entry, as you’d expect for a one-to-many link-from-form field.
C. Return to EDIT FORM 1 One-to-Many field, and do nothing except to click the radio button for Many-to-Many. DONE.
D. Go to FORM 2 and the single entry remains, and I haven’t really sorted out how it behaves, but it’s not like you’d expect for a Many-to-Many inverse relationship.It appears that once you select MTM as the link type with inverse relationship, the LINK FROM Field in the child form will ALWAYS appear as a MTM table, even if you later choose to make the parent field a OTM.
Similarly, if you select OTM as the link type with inverse relationship, the LINK FROM field in the child form will ALWAYS appear as a OTM single entry, even if you later choose to make the parent field a MTM.
I switched back and forth several times and found the observation to hold. This might not be the desired behavior.
My takeaway: Make absolutely certain that you know the Link Type you want when assigning an inverse relationship.
May 28, 2014 at 11:23 PM #10293
BrendanKeymasterYes, this does seem to be the behaviour. It’s not intended. But there is a workaround. After you change the Link Type even after you’ve saved the Link to Form field, uncheck the Show Inverse Relationship and check it again. This will delete and re-create the Link From Form field on the selected form. Tap Forms sets the Link Type on the Link From Form only when you enable the Show Inverse Relationship checkbox.
June 3, 2014 at 9:08 PM #10321
Frank TikketParticipantWould it be possible…. And I think many would agree to it, to have one field in a record display and EQUAL the same field in a different form.
Like a one to one or one to many. Basically on parent form the field “customer ID” would have a number and child form would also have a field “customer ID” and they are hot linked together. I know one to many does this, but it only displays the first 1-5 items of a form.
What if you want more than one item that doesn’t start in the first 5 items on the parent form? If I want to display the “customer ID” on both forms, and maybe display “customer name” on both forms (or whatever the field is)….. Some kind of hot linking where you can change in parent form or change in child form and it updates on all forms (I’m ok with even changing in just one form)
My biggest thing is id like to see the same data on both forms (parent and child) in individual cells/fields as opposed to just a table. This would help with calculation purposes as we’ll as exports… And keep things a lot more simpler and clean looking. Does anyOne agree?
June 4, 2014 at 10:30 AM #10330
BrendanKeymasterHi Frank,
This sounds like the idea I have for creating dynamic Link to Forms based on properties from the parent and the child. It’s kind of like being able to attach a Saved Search to a Link to Form. So rather than you having to manually select records to link to a parent form, the dynamic link type would do it for you based on some value that’s common between the parent record and the child records. Exactly like the database concept of foreign keys.
It’s just in the idea stage though.
Thanks!
Brendan
June 9, 2014 at 10:29 AM #10354
Frank TikketParticipantSure, it seems like the concept is already in place… just a different view is needed. Like on the many to many, you can DESELECT everything but that info you want to see. If only it would be formatted to look like native cell data instead of a link (basically you cannot modify it because its hot linked to another form: that, or you can modify and it changes both current form and other form)
Like I said seems like the concept is already working and things are already in place, just need a better visual on both iOS and mac. An idea would be when selecting a FIELD TYPE data, you just select a specific field from a different form and it just shows that data. Sounds very very simple, not sure whats needed on the programming side- but i think EVERYONE WOULD LOVE IT!! :-)
October 15, 2014 at 11:08 AM #11112
TeamSDAParticipantHello Brendan… Hope all is well. Is your new feature idea I quoted below in the works, i.e. will it be in the new Mac release just around the corner? I have set up some link to form field that I am populating via manually linking files but your search technique would automate the entire process.
Kind Regards,
Dave__________________________________________________________
Hi Frank,
This sounds like the idea I have for creating dynamic Link to Forms based on properties from the parent and the child. It’s kind of like being able to attach a Saved Search to a Link to Form. So rather than you having to manually select records to link to a parent form, the dynamic link type would do it for you based on some value that’s common between the parent record and the child records. Exactly like the database concept of foreign keys.
It’s just in the idea stage though.
Thanks!
Brendan
__________________________________________________________
October 15, 2014 at 12:16 PM #11114
Frank TikketParticipantYes, I am curious about this too… I was looking for direct linking (where one cell from one from displays in another cell from another form, and can be modified at either form).
Also, I am curious to when the engine overhaul will be completed that you talked about before that will make the database search much faster.
Thank you!
October 15, 2014 at 10:04 PM #11116
BrendanKeymasterThe next Mac update won’t have the dynamic link to form feature in it.
And Frank, I have only just started to work on the performance optimization overhaul. It’s at the very beginnings. In fact, I just started working on that last night. It’s going to require rewriting every form into separate tables in the database. It also means that a conversion process is necessary. Which also means that when this version comes out (no timeline on this yet), you’ll have to sit and wait for every bit of data to be read and then written to new tables in the database. It could take a while depending on how fast your device is and how much data you have. I have no performance benchmarks yet because the code is in its early stages, but I’m anticipating it could even take 1/2 an hour or more to convert some databases to the new format. Faster on the Mac version of course.
Along with that performance change because it requires a new way to represent the data on disk, it will also require changes to the iCloud syncing to match the changes to the database.
So tons of work. It’s going to be slow going. But I would like to focus on this for a while and not add any new features to the app until I get this done. That’s easier said than done of course. There’s always new features to implement.
Thanks!
Brendan
October 16, 2014 at 10:44 AM #11120
TeamSDAParticipantMany Thanks Brendan… So appreciate you taking the time to keep us up to date. I understand the complexities of developing tools like yours and value your dedication to making TapForms the best it can be.
Since moving to TapForms last Summer I have been designing my forms (Databases) in such a way that they will be able to take advantage of features that are part of what appears to be a logical progression of your fine product. It is with that in mind that I sometimes inquire as to what you may be planning for the future, even if it may be far off.
Kind Regards,
DaveJune 15, 2016 at 10:08 PM #17400
Joshua SouleParticipantI would really like to see dynamic linking of related fields. There are some situations where it’s just not practical to manually link each record to other records. I do a monthly import of all of our family’s financial transactions which is a few hundred transactions per month. I have another table which has the account numbers such as 123456789 with account nicknames such as “Family Checking”, etc. In most relational databases, I would just create a relationship between the “account number” in the transactions table and the “account number” in the nicknames table and anytime i view transactions I can also see the nickname of the account to make organizing the transactions easier, rather than a massive list of transactions with only account numbers to recognize them by. Can you tell me if this is a feature that is soon to come? Thanks.
-
AuthorPosts
You must be logged in to reply to this topic.