Tip #148: Simplify the customer lookup

In Dynamics CRM 2013 when you create a record such as a contact or opportunity that include the “Customer” lookup field that can resolve to an Account or Contact, and you type a company name in the customer field, you may get more results than expected.

customer lookup

This is because when you type in the customer lookup field, it searches both accounts and contacts. Since the contacts related to the account includes the account name in the Parent Customer field. When you search by company name, you will get the company and all of the contacts related to the company.

If you don’t want this to happen, go to Settings–>Customization and open the entity customization for the Contact entity. Open the View definition for the Quick Find view and click “Add Find Columns.”

Uncheck the box for parentcustomerid,  hit OK, save and close the view, then publish the contact entity.

With this change, typing a company name in a “Customer” field will only return company records. Searching contacts by account name will no longer work, but most users don’t search for contacts by account name. You can easily see an account’s related contact by navigating to the account record.

 

 

13 thoughts on “Tip #148: Simplify the customer lookup

  1. Peter says:

    I was interested in this because I’m working on a solution that requires the opposite – namely, I want to usually resolve to contacts and not accounts. Yet, if I used the solution above and try to limit the results to contacts – I can’t see the parentcustomerid field on the account object – just parentaccount – and that isn’t in the quick find view.

    I’m hoping to avoid using a custom lookup or JS on the field.

    Peter.

    • Joel Lindstrom says:

      you are trying to do the opposite of what the post suggests. when you type in the customer lookup it will search whatever is set as a fund column in the quick search view for accounts or contacts. it does not limit the lookup to only one entity, you can still click the lookup and select either entity. if you really want to limit this on opps or cases, these entities now also include separate lookups for account and contact that you can use instead of the customer lookup.

  2. Angus says:

    In CRM2015 the look fields are ParentCustomerID and Fullname.
    I’ve tried disabling both of these but the lookup continues to display both companies and contacts.
    By the way thanks for the blog!

    • Joel Lindstrom says:

      Angus,
      Thanks for reading the blog. This tip does not prevent accounts or contacts from being selected from the customer lookup. What it does is stop typing in the company name retrieving contacts that work for the company. If you want to do just accounts or JUST contacts (for cases or opps), switch to the “account” or “contact” fields. CRM 2015 now has separate account and contact lookups along with the “customer” field. If you add that field to the form and a user selects an account in the account id field, it will populate the customer field.

      • Angus says:

        Joel,
        Thanks for your reply. Actually I deselected both and selected Address 3 line 3 as at least 1 field had to be seleceted. From the Contact Quick input form it seems to work as required. However the chnage created problems by affecting contact and company lookups through out CRM so I had to reverse it. I’ll follow your suggestion.
        Angus

      • Wilco says:

        Hi Joel,

        It seems that my CRM online (2015) environment does not have the lookup fields account and contact you’d mention. Can you please provide me with more specific information on these two fields and where to find them?

        Regards,
        Wilco

        • Joel Lindstrom says:

          It is on the opportunity. They are not displayed on the form, but are in the field list and can be added to the form.

  3. Shabeer says:

    Hi, I have tried to do the following but it still displays both contacts and Accounts in the search. If I try to search for a contact, I am able to find them and relate them to the other contact. Is there another way?

    • Joel Lindstrom says:

      Add an account lookup and hide the customer lookup. Have a process populate the customer lookup with the value selected in the customer lookup.

    • Joel Lindstrom says:

      the other way is to use a custom lookup for just accounts or contacts. You can then set the value of the customer lookup to what is selected in the new lookup.

  4. Gaurav sharma says:

    Thanks a lot for putting out great simple tips guys. I have used this blog to do many effective things that have helped improve user experience.

Leave a Reply

Your email address will not be published. Required fields are marked *