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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Dynamics 365 - populat...
Power Automate
Unanswered

Dynamics 365 - populate Org Name dynamically, so Org can be set once and used throughout flow

(0) ShareShare
ReportReport
Posted on by 29

I have a flow with many steps that connect to a D365 CRM Org ("DevOrg1"). When I move this solution to another environment, I need to change the Organization Name to that environment ("ProdOrg1"). The connection stays the same, but the Org is different.


What I would like to do, is declare the Org Name as a variable at the beginning of the flow, and use that value as a custom value in each D365 step. There's too much room for error when manually updating each step to point to the new connection. I have tried the GUID of the org, as well as the text value of the Org name, but neither worked.


Does anyone know what value should be used? There's obviously more going on behind the scenes that I'm unable to replicate.

Categories:
I have the same question (0)
  • v-alzhan-msft Profile Picture
    on at

    Hi @jamesreinhardt ,

     

    You could initial a string variable in the begainning of the flow, and insert the Organization Name in the variable, then you could use the variable value in the following steps, so every time when you want to change the Organization Name for different environment, you just need to update the value for the string variable.

     

    Best regards,

    Alice       

     

    Community Support Team _ Alice Zhang
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

  • James Reinhardt Profile Picture
    29 on at

    Thanks for the reply, but unfortunately that didn't work. It appears that the 'selector' is doing more than just giving the step the string of the Org Name. Unfortunately I don't have a way to peek at that part of the code to see exactly what is being passed in.

     

    I might try using one of the CDS steps and see if that behaves any differently.

  • Verified answer
    James Reinhardt Profile Picture
    29 on at

    I think I've found the solution, but need to test it out a bit to be sure. Rather than use the "Dynamics 365" steps which require a specific organization be specified, I used a "Common Data Service" step, which has an option for "Current" environment. It appears that these steps are aware of the environment that the solution is in and wouldn't require declaring the specific Org at all.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 364 Moderator

#3
abm abm Profile Picture

abm abm 243 Most Valuable Professional

Last 30 days Overall leaderboard