Skip to main content

Notifications

Microsoft Dynamics CRM (Archived)

workflow to trigger a lookup

Posted on by 365

I have a custom entity that is going to capture the first name, last name and email address of a person.

I need the creation of this entity to trigger a workflow that will achieve the following.

- Check to see if this person already exists as a contact in CRM.

- If so, then update the custom entity with a lookup to that contact record.

- If they are not in CRM then create a contact record with the details and then update the custom entity with a lookup to the created record.

Basically, I have data coming in from an external source and they cannot lookup data in Dynamics so I need them to dump the data in the custom entity and Dynamics will then look them up and act accordingly. 

*This post is locked for comments

  • Suggested answer
    gdas Profile Picture
    gdas 50,085 on at
    RE: workflow to trigger a lookup

    Hi ,

    As per my understanding  you need to check the duplicate records exists in contact at the time of creating custom entity record and update and create accordingly the custom entity.

    I don't think in OOB workflow its possible . In that case it's good to go for plugin .

    Hope this helps.

  • Suggested answer
    CU18090919-0 Profile Picture
    CU18090919-0 80 on at
    RE: workflow to trigger a lookup

    You can achieve this by two ways

    1) JavaScript

    You can add javascript onSave when you will save record then script will find record(retrieve multiple ) on the base of email. If record found then you will create lookup relationship with contact otherwise create new record.

    2) Plugin:

    You can register plugin and write your business logic to achieve this functionality.

    Better Approach: You should use plugin because it will work for external source.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,253 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,188 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans