Answered by:
crm 2011 lookup question

Question
-
Hi, when I set the lookup for account (say in a custom entity), the lookup shows all the account NAME. Is there a way for me to display the ACCOUNT NUMBER instead of ACCOUNT NAME? Appreciate your help and suggestions.Wednesday, August 17, 2011 12:05 PM
Answers
-
You would have to use duplicate detection rules: Create your custom duplicate detection rule and publish it.
Gonzalo | gonzaloruizcrm.blogspot.com
- Marked as answer by CRM elite Friday, August 19, 2011 1:18 PM
Friday, August 19, 2011 1:14 PMModerator -
Hi,
You may reffer to the following post for Duplciate Detection rules guide (http://blogs.msdn.com/b/crm/archive/2007/11/20/duplicate-detection-rules-defined.aspx) it is for CRM 4.0 but funcitonality is almost similar.
Jehanzeb Javeed
http://worldofdynamics.blogspot.com
Linked-In Profile |CodePlex Profile
If you find this post helpful then please "Vote as Helpful" and "Mark As Answer".- Marked as answer by CRM elite Friday, August 19, 2011 1:18 PM
Friday, August 19, 2011 1:15 PM
All replies
-
Hi,
There is no way to change the system default look field behavior and you can not change this. What you can only do is to use a new custom field for Account Name and for Account Number can use the name field.
Jehanzeb Javeed
http://worldofdynamics.blogspot.com
Linked-In Profile |CodePlex Profile
If you find this post helpful then please "Vote as Helpful" and "Mark As Answer".- Proposed as answer by Jehanzeb.Javeed Wednesday, August 17, 2011 12:18 PM
Wednesday, August 17, 2011 12:18 PM -
The lookups in CRM will always use the "Primary Field" of an entity. The primary field cannot be updated and can only be specified when creating a new custom entity. However, you are still able to change the Labels on the fields, which is a little hack but it might work for you. If you interchange the label name for the account number and account name then the lookups will use the data you enter in the "account number" field. The problem is that it can be confusing when accessing the data from the SDK since the field names are inverted, but it might work fine for you.
Gonzalo | gonzaloruizcrm.blogspot.com
- Proposed as answer by Gonzalo Ruiz RModerator Wednesday, August 17, 2011 12:35 PM
Wednesday, August 17, 2011 12:34 PMModerator -
Hi Thanks, I interchanged the labels for these fields Contract ID and Contract Name on the Contract Form. Or Do I need to change the display name of these fields? I placed a lookup for Contract in a Custom Entity. However, the lookup still displays the name of the account record.
ie. From the Lookup, click search --> choose the contract record --> lookup display the name of the contract but not the contract ID.
Friday, August 19, 2011 11:00 AM -
Hi,
Yes if fields now name field has Id and Id field has name then you can change the display name of the fields (remeber thatcontract number is a system autogenterated field and contains contract number) and can add the contract Id into the Contract Lookup View and Qucik Find all Contracts view, go to Setings->CUsotmizaiton->Cusotmizations->Cusotmize teh System->Entities->Contract->Views (Open Contract Look View and Quick Find all Contracts view and click on Add Columns button to add columns as per required)
Jehanzeb Javeed
http://worldofdynamics.blogspot.com
Linked-In Profile |CodePlex Profile
If you find this post helpful then please "Vote as Helpful" and "Mark As Answer".
- Proposed as answer by Jehanzeb.Javeed Friday, August 19, 2011 11:10 AM
- Edited by Jehanzeb.Javeed Friday, August 19, 2011 11:12 AM Updated
Friday, August 19, 2011 11:10 AM -
Hi, yes what I mean by "label" was actually the display name. If you interchange the display name for the fields, then make sure you publish all customizations. Then of course you would need to interchange your data as well for existing records so you move the number to the name and viceversa. Then everything should work as expected. For new records there is no actions required.
Gonzalo | gonzaloruizcrm.blogspot.com
- Proposed as answer by Gonzalo Ruiz RModerator Friday, August 19, 2011 12:47 PM
Friday, August 19, 2011 12:47 PMModerator -
Thanks Ruiz, But I noticed that the system allows duplicate values! I switched the ID and name. Now how can I prevent the dups?at if I can control the dups on the Contract ID (formerly Contract name) that will be helpful. Now both new Contract ID and Contract Name allows dups.Friday, August 19, 2011 1:11 PM
-
Hi Jahanzeb, I tried this as well. But the question is how to control dups?Friday, August 19, 2011 1:13 PM
-
You would have to use duplicate detection rules: Create your custom duplicate detection rule and publish it.
Gonzalo | gonzaloruizcrm.blogspot.com
- Marked as answer by CRM elite Friday, August 19, 2011 1:18 PM
Friday, August 19, 2011 1:14 PMModerator -
Hi,
You may reffer to the following post for Duplciate Detection rules guide (http://blogs.msdn.com/b/crm/archive/2007/11/20/duplicate-detection-rules-defined.aspx) it is for CRM 4.0 but funcitonality is almost similar.
Jehanzeb Javeed
http://worldofdynamics.blogspot.com
Linked-In Profile |CodePlex Profile
If you find this post helpful then please "Vote as Helpful" and "Mark As Answer".- Marked as answer by CRM elite Friday, August 19, 2011 1:18 PM
Friday, August 19, 2011 1:15 PM -
Thanks a lot Gonzalo & JehanFriday, August 19, 2011 1:19 PM