2 Replies Latest reply on Sep 30, 2014 12:08 PM by wsvp

    Displaying Portal Records if One of Two Conditions Are Met


      I have a database that tracks issues that occur between companies. Two tables, Company and Issues. On the company table, each company has a unique identifier code. When a new issue is created in the issues table, the user is able to enter up to two companies that are affected by the issue (i.e. Company A is in dispute with Company B over shipping terms). Company A's code is then stored in issues::Company Referenced 1, and Company B's code is stored in issues::Company Referenced 2. I'd like to have the portal on my company layout display records if the company is referenced in issues::Company Referenced 1 OR issues::Company Referenced 2. Is this possible? Thanks.

        • 1. Re: Displaying Portal Records if One of Two Conditions Are Met

          Yes, you could use a cartesian join to the issues table, then filter the portal to that table to display only where: Company::Identifier = Issues::Ref1 OR Company::Identifier = Issues::Ref2.


          Might be easier though to setup a proper many-to-many relationship though, as using a cartesian join can lead to performance issues down the road for displaying portal records.

          • 2. Re: Displaying Portal Records if One of Two Conditions Are Met

            In addition to Mike's point (which I agree with,)... "Portal Filtering" is ignored by functions like... Sum, Last, List, Average, Count, etc... and by script steps like GoToRelatedRecord, thus only the actual relationship is evaluated.  That being said, there are many times when Portal Filtering is handy, like a popup search/selector referencing a low volume table.  If the table being referenced holds a high volume of records, it is best to use the relationship to filter down the list, then perhaps use a Portal Filter to refine that set, (keeping in mind the Function issue.)