Using Related Objects

Share This Post

Share on facebook
Share on linkedin
Share on twitter
Share on email

Search 3B Knowledge Base

You are here:
< Back

What are form Related Objects?

Simply put, a related object is an object connected somehow to the main object. There are generally two types of relationships supported by 3B Forms:

Salesforce Classic UI Salesforce Lightning UI
Child Relationships – child objects are usually what you can see in a “Related List” against a salesforce record. They are connected through one or multiple* fields through to the “main” object of the form.

For example, we have “Education” Object which records education history for a contact. On the Education Object, we have a field which points to the Contact object. This is what we call a “Lookup Field” which can be one of 2 types – Lookup or Master detail.

 

Parent Relationships – a parent relationship is where the record on which we have based the form on is the child in the relationship. This usually looks like a field on a record.

Here is an example where a Contact is linked to an Account. This is what we call “Parent Object Relationship”

*An object can have multiple Lookup Fields to another object, self-reference is also possible (where an object has a lookup to the same type object)

Using Child Records

Lets take an example, where we are creating a Form which will allow user completing it to log multiple Cases, connecting their Contact record to the Case.

To achieve this, we need to create a form based on the Contact Object and add a Related Object based on “Case” object.

  • Click on “Add” Button and select “Related Object” and a pop up will open
  • Give it a “Title” – this will be displayed on the form
  • Search for “Case” in the Related Object drop down
    • You may have more than 1 Case option available. Next to the name of the object, you will see the name of the connecting field. In the example below, we have 3 fields on the Case which look up to Contact
    • Select the option that best suits your scenario
  • The two tables (Fields to Choose  Fields Chosen) will re-fresh and you will be presented with all the fields on that related object
    • Required fields will be automatically added to “Fields Chosen”
  • Click on the fields you want to add and then click on “Add Selected”
  • Set the toggle Repeatable  to “Yes”
    • Setting this toggle to Yes means that a user completing the form can create multiple records (user can create multiple cases)
    • Leaving it at No will allow the user completing the form to only create one related record (user can submit only one case at a time)

 

List of Related records – note Case (500) has multiple entries Selecting fields to add to the form

 

That’s It!

Using Parent Records

Lets take an example, where we are creating a Form which will allow user completing it to create an Account and attach it to a newly created Contact.

To achieve this, we need to create a form based on the Contact Object and add a Related Object based on “Account” object.

  • Click on “Add” Button and select “Related Object” and a pop up will open
  • Give it a “Title” – this will be displayed on the form
  • Search for “Account” in the Related Object drop down
    • You need to look for the Account field in the “Lookup Objects” section
  • The two tables (Fields to Choose  Fields Chosen) will re-fresh and you will be presented with all the fields on that related object
    • Required fields will be automatically added to “Fields Chosen”
  • Click on the fields you want to add and then click on “Add Selected”
  • The toggle Repeatable  will be disabled as you can only have one Parent in a Parent-Child relationship.

That’s It!

Notes:

  • In the Related Objects pop-up, in the drop down “Related Object”, you will notice that against each entry there is a code in brackets (for  example Contact (003)) – this is so we can identify which object you want to use in the scenario where you have multiple objects with the same name
  • Remember to add a “Limit SOQL” statement to avoid exposing too much/irrelevant data to the form user if the form is going to be used in pre-populate mode

Subscribe To Our Newsletter

Get updates and learn from the best

More To Explore

3B Initiative

Gaby F – 5 Stars

Multiple use cases for multiple Salesforce implementations Thank you so much for the review, Gaby – it is always pleasure working with you and the

3B Initiative

Colette B – 4 Stars

3B Forms Thank you so much for the review, Colette – we are lucky to have clients like you on our portfolio! The exact coordinates

Product Features

User Tracking

Understand how long users take to submit a form and where they are at.

Innovate, improve, empower. We believe engaged and happy customers make great partners, and see continuous feedback and collaboration as key levers in our shared drive for success. You need a small customisation to fit that nonconforming process step you have? We are more than happy to offer it free of charge. You have a recommendation for improvement/feature implementation? We are happy to listen, and will issue you with a special certificate to credit you for an idea that goes into the product.

As (we hope) you probably guessed yourself already – we want to be the single most flexible and customer-friendly forms solution on the market.