1 Reply Latest reply on Feb 1, 2014 2:26 AM by erolst

    Related fields

    colinmatthews

      Hi all,

       

      Is there a way of making a field ID match that of the record in another table so that they match and can be shown in a portal?

       

      I have a Customer layout and a Tasks layout. I have a portal on the Customer layout from the Task layout. The problem is that if I add 5 Tasks to Customer #1 in the portal window then these tasks are added to customers 1-5 rather than all in Customer #1.

       

      I realise that this is because both the Customer PK field and the Task FK field are set to auto-increment by 1 and have therefore tried the alternative options but none of these seem to work.

       

      Any pointers would be greatly appreciated.

       

      Thanks,

       

      Colin

        • 1. Re: Related fields
          erolst

          colinmatthews wrote:

          I realise that this is because both the Customer PK field and the Task FK field are set to auto-increment by 1

          That's the correct setting for a primary key, but you don't define a foreign key as serial increment; it is simply to receive the value of a primary key.

          and have therefore tried the alternative options but none of these seem to work.

          Make it an ordinary number field without auto-entry options; if the relationship is matching Customer::customerPK to Task:customerFK, then on creating a new portal row the foreign is set automatically, i.e. you are creating a related record.