Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

FetchXML query

(0) ShareShare
ReportReport
Posted on by 821

Using fetchxml I have an account name and a secondary name but I want the secondary name to override the account name if it contains data. Is there a simple way I can do this using fetchXML. The data is used to dynamically populate a lookup on the D365 portal

 

Thanks G

*This post is locked for comments

  • Suggested answer
    Mahendar Pal Profile Picture
    45,095 on at
    RE: FetchXML query

    In liquid you can use client script code to manipulate your entity form fields. if you have alread tried it, share it here for checking.

  • gman0104 Profile Picture
    821 on at
    RE: FetchXML query

    Since i am dealing with Portals and Liquid I will have to retrieve the account name and secondary name and the used liquid to override the account name if the secondary name exists to populate my dropdown which will be a mixture of account name and secondary names

  • Suggested answer
    RaviKashyap Profile Picture
    55,410 Moderator on at
    RE: FetchXML query

    Hi,

    FetchXML is used to retrieve the data. To update the data, need to write some custom logic using either of the following - Workflow, Plugins, JS etc.

    I guess for you the best option would be to use a real time workflow on account entity which triggers on create & onchange of secondary name. Within that workflow, you can update the account name with secondary name.

    Hope this helps.

  • Suggested answer
    Temmy Wahyu Raharjo Profile Picture
    2,914 on at
    RE: FetchXML query

    Hi

    I believe there is no way to do it on the fetchxml. You can fetch both data (primary and secondary), then on your logic if the primary is null, you pick the other way.

  • Mahendar Pal Profile Picture
    45,095 on at
    RE: FetchXML query

    Hi,

    Can you share some more details what you are trying to do, you can write JS/Jquery code to set field value on the portal but you can share some more details it will help.

  • Suggested answer
    Alex Fun Wei Jie Profile Picture
    33,626 on at
    RE: FetchXML query

    Hi,

    First,which method you would like to use? workflow, plugin or etc?

    You can create a workflow to do that, trigger on update and create, check if secondary name contain data, then create a update step to update the primary name.

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

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

Leaderboard > Microsoft Dynamics CRM (Archived)

#1
Mohamed Amine Mahmoudi Profile Picture

Mohamed Amine Mahmoudi 83 Super User 2025 Season 1

#2
Community Member Profile Picture

Community Member 54

#3
Victor Onyebuchi Profile Picture

Victor Onyebuchi 6

Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans