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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested Answer

Can I debug UAT code in DEV in D365FO

(0) ShareShare
ReportReport
Posted on by 308
Dear team,
 
Can I debug UAT code in DEV in D365FO . For example, for specific reason I needs to debug a piece of code in UAT. 
In UAT, we can't debug it 
 
Kindly elaborate pls, how will I get the UAT code in DEV.
 
What is the best approach.
 
Kindly elaborate pls.
 
thanks!
Categories:
I have the same question (0)
  • Suggested answer
    André Arnaud de Calavon Profile Picture
    305,678 Super User 2026 Season 1 on at
    Hi,
     
    The correct process for debugging UAT is described in this article: Debug a copy of the production database - Finance & Operations | Dynamics 365 | Microsoft Learn
  • Suggested answer
    Shaluma Profile Picture
    151 on at
    Hi,
     
    Yes, you can debug UAT logic in a DEV 
    To ensure your DEV environment matches UAT exactly, you must pull the specific code version from your source control system.
    Check the installed product version and package version in UAT, Find the corresponding release branch or changeset  in Azure DevOps, Open Visual Studio in your DEV environment. Connect to the correct branch and perform a Get Latest  to pull that exact codebase into your local metadata store. Run a full build of your models in Visual Studio.
    Move the UAT DB to DEV 
    Most UAT-specific bugs happen because of unique data configurations. You need the UAT database in your DEV environment.
     Go to the Lifecycle Services (LCS) project. Navigate to the environment details page for UAT. Go to Maintain > Move database and select Export database to create a bacpac file. Download the bacpac file from the LCS Asset Library.Use the SqlPackage.exe command-line tool on your DEV machine to import this bacpac file into your local SQL Server instance (replacing the existing AxDB). Run a full database synchronization from Visual Studio to align the restored database with your local code.
    Once your DEV environment has the exact same code and data as UAT,Open Visual Studio Run Visual Studio as an administrator.Open the specific element or class where the error occurs and insert your breakpoints. 
    • Go to Debug > Attach to Process, For IIS-hosted environments, attach to w3wp.exe,IIS Express environments, attach to iisexpress.exe, batch jobs, attach to Batch.exeOpen the D365FO browser link from your DEV machine, perform the action that caused the issue in UAT, and the debugger will hit your breakpoint. 
    If you cannot overwrite your DEV environment's code or database, you can use Trace Parser as an alternative: 
    Run a performance/execution trace in the UAT environment while replicating the bug. Download the trace file Open the trace file using the Trace Parser tool on your DEV machine to inspect the exact call stack, queries, and variable inputs without attaching a live debugger.
    https://d365ffo.com/2021/07/24/ax-d365fo-how-to-use-trace-parser-as-a-debugger/

    Thanks,

    If you found it helpful, please consider marking it as verified â€” it may be useful for others in the future!
     

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

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Abhilash Warrier Profile Picture

Abhilash Warrier 628 Super User 2026 Season 1

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 501 Super User 2026 Season 1

#3
Subra Profile Picture

Subra 437

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans