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 :
Finance | Project Operations, Human Resources, ...
Suggested Answer

update data on when doing Prod to UAT refresh

(2) ShareShare
ReportReport
Posted on by 247
Hi all,
 
I would like to know if there is way to automate the update of data when doing Prod to UAT database refresh.
 
For e.g. when we moved data from Prod to UAT, the electronic email address and others tables get empty.
 
In the same manner, can we define with our own logic to clean some custom tables?
 
We have lots of integrations, we would like to empty the Production settings (urls and etc) when doing UAT refresh.
 
Pls let me know what approaches we can take other then manually running sql script.
 
Thank you
I have the same question (0)
  • Suggested answer
    Adis Profile Picture
    6,069 Super User 2025 Season 2 on at
    Hi,
     
    We have a similar issue with the printing setup, although its a minor one that we are doing manually as we dont copy PROD to Sandbox very often.
     
    The way I would do it is with Power Automate (PA). We automated already some tasks with PA, f.e. all users are deactivated after a copy, so we check for active users in PROD and set them to enabled in the sandbox. Also some batch jobs are being activated by PA as they are deactived after the copy.
     
    The "only" thing that you propably will struggle with is the missing entities, especially if you wanna address custom tables. So, if you cant find a proper entity\field in PA its because it doesnt exist or a table\field is missing in the entity. Then you need to extend the entity or create a new one, however, for a developer it shouldnt be much of a work.
     

    Kind regards, Adis

     

    If this helped, please mark it as "Verified" for others facing the same issue

    Keep in mind that it is possible to mark more than one answer as verified

  • Suggested answer
    Nisarg  Jani Profile Picture
    529 on at
    Hi,
     
    To remove the Production settings for custom tables you can create runnable class to remove such tables data, It can run(https://abc.cloud.onebox.dynamics.com/?cmp=abc&mi=action:ClassName) after the UAT(Sandbox) database refresh.
     
    Regards,
    Nisarg Jani
  • Raj Borad Profile Picture
    1,428 on at
    Hi,

    It depends on how often the data refresh activity is performed and how much data needs to be removed from the UAT after data refresh.
    Nisarg's suggestion related to the class which deleted unwanted data from UAT is applicable if the number of data refreshes is more in a short period, and unwanted data must be removed from the UAT instance.
     
  • André Arnaud de Calavon Profile Picture
    301,194 Super User 2025 Season 2 on at
    Hi Jeff,
     
    In case your environments are linked with a Power Platform environment, you can use environment variables and use X++ logic to retrieve or set them.
    This is possible in the latest versions of Dynamics 365 F&O.

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 > Finance | Project Operations, Human Resources, AX, GP, SL

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 467 Super User 2025 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 420 Most Valuable Professional

#3
BillurSamdancioglu Profile Picture

BillurSamdancioglu 241 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans