2 Replies Latest reply on Mar 13, 2014 6:34 AM by john.s

    Trouble Filtering Portal with Relationship



      Trouble Filtering Portal with Relationship


      I have a layout based on Schools with a portal to a self join table to allow selection of schools based on an active non active code.  The school portal “goes to related records” and has two more portals on the same layout.  The goal is to have a single row portal to a SchoolStaff table with the contact information for the Principal and a second portal with the remaining staff.  I set up the two portals because I could not sort and get Principal at the top.  The Value List for school staff is a list of Custom Values and I allow it to be edited because all schools don’t use the same names for their staff positions.  I have tried to set up the relationships so I can add new contacts using the portal but it is not working.  I set up a self join table with a relationship to select records when the Staff Position field is Not Equal to a global field set to “Principal”.  The relationship table will not allow me to Enable the Creation of Records and I’m assuming that is because of the “Not Equal” relationship.  I can’t figure out a way of filtering the portal with relationships and still be able to create records with that relationship which I believe from reading several posts is the best way to get a window to refresh in a reasonable timeframe.  I’m thinking I can add another table occurrence with the Position = global Position so both join tables are filtered by the relationship and then create records with a script but it seams like there should be an easier way.


      This is what I have so far.


      Schools --> SchoolStaff

      with following Relationship

      Schools:__pk_SchoolCode  = SchoolStaff:_fk_SchoolCode



      Also using an occurrence of SchoolStaff


      Schools --> SchoolStaff | isn’t Principal   

      with following Relationship

      Schools:__pk_SchoolCode  =  SchoolStaff | isn’t Principal:_fk_SchoolCode


      Schools:cg_Position  not equal  SchoolStaff | isn’t Principal:Position


      cg_Position is a global calculated field with a value of “Principal” with result being text


      At this point my brain is toastany help will be greatly appreciated