Best way to handle many - many relationship between User & Business Unit. One user can belong to many business units & a business unit can be associated with several users.

Soln: Create junction object with lookup to standard user object & lookup to custom Business Unit object which captures the business units.

Concern with soln: User needs to be maintained in the custom junction object as well as the standard user object. I would prefer a solution where once user is added / deleted with Business unit info the junction object should be automatically updated.In my solution the standard user object does not capture business unit information (because of many-many relationship). The link with business unit and user is made in the junction object. This means the user in the user object is not linked with the business unit. The solution seems clunky. Any suggestions on how this can be accomplished?

1 Answer 1


yes to achieve many to many relationship we can use parent child relationship aka Master Derail.you have to create junction object between user and business unit but i am not getting your point what you want to know since its master detail relationship any change in user and business unit object(parent) also effect child(junction object)it will automatically update child records.The user in user object dosent link with business unit thats why we are creating (junction object ) to perform many to many relationship.

For more info read below

from reference to recruiting applications .let assume you have two objects positions and Employment Website we can link them using a junction object because

• One position could be posted on many employment websites.

• One employment website could list many positions.

For our app, we're going to create a junction object called Job Posting. A job posting fits into the space between positions and employment websites—one position can be posted many times, and one employment website can have many job postings, but a job posting always represents a posting about a single position on a single employment website. In essence, the Job Posting object has a many-to-one relationship with both the Position and the Employment Website objects, and through those many-to-one relationships, we'll have a many-to-many relationship between the Position and Employment Website objects.

Let's look at a typical scenario at Universal Containers(RECRUITING APP). There are open positions for a Project Manager and a Sr. Developer. The Project Manager position is only posted on Monster.com, but the Sr. Developer position is more difficult to fill, so it's posted on both Monster.com and Dice. Every time a position is posted, a job posting record tracks the post. As you can see in the following diagram, one position can be posted many times, and both positions can be posted to the same employment website. read this info might be it  will help you

if you delete an employment website record, all of its associated job posting records are deleted

  • I would like to ensure that every time a new user is created a business unit is entered for the user. Since there is no business unit field in the user object it is difficult to enforce business unit be entered every time a new user is created. It would be nice if the user object could have a picklist with various BU's allowing multiselect (I know this cant be done). I want to be able to report on business unit along with other details in the user object because thats where all the data related to the user is maintained. What is the best way to accomplish my goal?. Commented Mar 16, 2015 at 3:04

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .