2 Replies Latest reply on Jan 3, 2011 7:46 PM by KenKing

    5 Fields, 1 Table: 5 TOs or 1 Portal?

    KenKing

      Title

      5 Fields, 1 Table: 5 TOs or 1 Portal?

      Post

      One Invoice can have 5 contacts (Buyers, Sellers, Agents etc).  Currently I have 5 TOs of "Contacts" related to the Invoice TO, to accomodate the 5 contact fields on the Invoice layout.  

      If I wanted to simplify things, I could get rid of the 5 Contacts TOs in favor of 1 Contact TO, and use a portal on the invoice Layout (in which case I could have many more than 5 contacts).  This I read from one of Philmodjunks prior posts.

      However, using the portal method doesn't seem to fit my goals because i) I dont want to create new contacts via the portal.  Instead I want to select the contacts from a drop down list based on the Contacts table.  

      I cant figure out how to do that, if its possilbe. Any suggestions?

      Thanks!

        • 1. Re: 5 Fields, 1 Table: 5 TOs or 1 Portal?
          philmodjunk

          You can certainly use a portal instead of 5 different TO's. That seems much more efficient and flexible. Portals can be used for data display only, you can use behavior settings for each field in the portal to prevent entry while in file mode and you can use a relationship that doesn't allow creation of related records if you want to make this a read only portal.

          I want to select the contacts from a drop down list based on the Contacts table.  

          That can certainly be done, whether you have 5 TO's or just one. I think you want to select up to 5 different contacts to associate with a given invoice record. Is that correct?

          If so, you can use a join table and link any number of contacts with any number of invoices.

          Invoices---<invoice_contact>----Contacts

          Invoices::InvoiceID = Invoice_Contact::InvoiceID
          Contacts::ContactID = Invoice_Contact::ContactID

          You'd use a portal to invoice_contact to create new records in this table, with a drop down of contact IDs to link each new Invoice_Contact record to a specific contact record.

          • 2. Re: 5 Fields, 1 Table: 5 TOs or 1 Portal?
            KenKing

            I see now I was trying to create a "many-to-many" relationship,  I should have realized I needed a join table (and that a portal doesn't obviate relationship structures but, of course, is defined by them).

            Thank you, PhilModJunk!