1. Open as Administrator PowerShell
Install if not installed d365fo.tools
Install-Module -Name d365fo.tools Invoke-D365InstallSqlPackage
2. Restore database BACKPAC
import-D365Bacpac -ImportModeTier1 -BacpacFile "C:\Users\Admin\Downloads\AxDB.bacpac" -NewDatabaseName "AxDB_New" -ShowOriginalProgress
3. Stop environment
Stop-D365Environment
4. Switch databases
Switch-D365ActiveDatabase -SourceDatabaseName "AxDB_New" -DestinationSuffix "_old"
Where _old is postfix for currently used AxDB, it will be called AxDB_old
5. Start environment
In powershell
Start-D365Environment
5. Sync database
Dynamics 365 / Synchronize database…