web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

How to search multiple values in lookup records screen

(0) ShareShare
ReportReport
Posted on by 204

How can i add multiple values in the search box for lookup records highlighted yellow box. 

E.g. i want to find aa@hotmail.com and ab@hotmail.com 

5556.lookup.JPG

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    bac26 Profile Picture
    2,268 on at

    you cannot do this out of the box.  Only thing you can do is wild cared a*@hotmail.com or one then the other.      

    You can do a private view and do a field = aa@hotmail.com or field = ab@hotmail.com but you cannot do it out of the lookup box.

  • r4vvm Profile Picture
    204 on at

    Basically i have a big list of email addresses i want to search for so want to copy and paste them to search and then it will bring a list up on their contact id's so need a way to do this rather than searching for 1 by 1

  • Suggested answer
    bac26 Profile Picture
    2,268 on at

    if there is nothing in common with the email addresses or users, it is not possible without scripting something or using another tool.  This is not a native function.

  • Suggested answer
    Pawar Pravin  Profile Picture
    5,237 on at

    Hi,

    Unfortunately its not possible in CRM by OOB functionality.

  • TrevorB Profile Picture
    105 on at

    Hi r4vvm

    It would be great if there was a simple way of doing this but as others have pointed out there doesn’t seem to be any OOB solution. I needed to do something similar on a regular basis so my work around it to use the XRMtoolbox - Fetchbuilder and Excel. It’s a bit of a clunky solution but is a way of getting the desired result. Create your basic view in advanced find manually adding the first two email address and save.  Open that view with the Fetchbuilder and view the fetch. My example is account based so it look like below.

    < fetch version="1.0" output-format="xml-platform" mapping="logical" distinct="false">

     <entity name="account">

       <attribute name="name" />

       <attribute name="primarycontactid" />

       <attribute name="telephone1" />

       <attribute name="customertypecode" />

       <attribute name="accountid" />

       <order attribute="name" descending="false" />

       <filter type="and">

         <filter type="or">

           <condition attribute="name" operator="like" value="Test1%" />

           <condition attribute="name" operator="like" value="Test2%" />

       </filter>

     </filter>

    </entity>

    </fetch>

    I create a an Excel workbook where I paste my list of data I want to search for in column A.  In column B I copy and paste the first part of the fetch code that searches for the account name being

    <condition attribute="name" operator="like" value="

    Then in column C the last bit of the fetch being: %" />

    In column D using the Concatenate function we bring the code back together

    =concatenate(B1,A1,C1). Highlight B1:D1 and double click he fill handle you now have x lines of code ready to be pasted back into your view using XRMtoolbox fetch builder replacing the text between

    <filter type="or">

           (Paste code between these lines)

       </filter>

    I usually paste out to notepad first to clean up the formatting before pasting into the Fetchbuilder (it will add the cell borders otherwise.

    Save your view and now when you open your view in Dynamics it will return and matched results. I would also save your excel file for future use. My workbook has grown over the last couple of years with worksheets for querying different entities, searching for part and exact matches etc.

    As I mentioned this is a bit clunky but sure beats creating a advanced view manually entering in hundreds of queries and you can then use the template over and over. I would be interested to hear if anyone else has a is  simpler solution.

    BTW: there is a 500 max queries results that can be returned so keep that in mind.

    Hope this makes sense and is of some help.

  • Suggested answer
    antc Profile Picture
    2,909 on at

    Trevors solution will help you out.

    What are you trying to do with this lookup?

    The other option would be to use Visual Studio SSIS with the KingswaySoft connector for CRM. You can then have a SQL table with your list of email addresses and do a lookup against the entity records. The benefit with this is you can then transform the data, add columns etc and update back into Dynamics at the same time.

    Here is a basic example of updating the prices for Products in Dynamics. The lookup contains the link to the SQL table. Usually I will have error outputs and send them to SQL as well however this one was basic and I knew that all records where in both Dynamics and SQL so just had the Union All in case I was wrong

    cap7.JPG

  • Suggested answer
    MehranBre Profile Picture
    732 on at

    Hello,

    I also had search problem in Microsoft Dynamics until I developed my own solution.

    its simple and fast to use!

    You can use it now

    I think this is exactly what you wanted

    GitHub link: github.com/.../Microsoft-Dynamics-365-Advanced-Search

  • r4vvm Profile Picture
    204 on at

    Hi,

    Have you got any videos/screenshots of how it works?

    Be interested to see

  • Suggested answer
    MehranBre Profile Picture
    732 on at

    hi,

    yes you can see tutorial video (3 minutes) in GitHub:

    github.com/.../releases

  • tdav246 Profile Picture
    5 on at

    This is a great solution! Thanks

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans