Personalized Community is here!
Quickly customize your community to find the content you seek.
Check out the latest Business Central updates!Learn about the key capabilities and features of Dynamics 365 Business Central and experience some of the new features.
Download overview guide | Watch Business Central video
2021 Release Wave 1Discover the latest updates and new features to Dynamics 365 planned April 2021 through September 2021.
Release overview guides and videos Release Plan | Preview 2021 Release Wave 1 Timeline
The FastTrack program is designed to help you accelerate your Dynamics 365 deployment with confidence.
FastTrack Program | Finance and Operations TechTalks | Customer Engagement TechTalks | Upcoming TechTalks | All TechTalks
We have encountered the error below when upgrading the database from BC16.1 to BC 16.2. Previously the database is upgraded from BC15 to BC16.0, then we upgrade from BC16.0 to BC16.1 when released. We upgraded smoothly with no issue. Recently, we tried to upgrade the database to latest BC version(16.2) but hitting the error below when running this command: Sync-NAVTenant -ServerInstance BC161 -Tenant default -Mode Sync -Force
Upgrading the standard database has no issue. But hit the error when upgrading the customer database.
Any hint for this error is much appreciated. Thank you
Here is the error taken from EventViewer:
Message (ArgumentException): RootException: ArgumentExceptionAn item with the same key has already been added.ExceptionStackTrace: at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource) at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add) at Microsoft.Dynamics.Nav.Runtime.Apps.CompanionTablePrimaryKeyFixer.GetTablesGroupsWithWrongPrimaryKey() at Microsoft.Dynamics.Nav.Runtime.Apps.CompanionTablePrimaryKeyFixer.GetCommands() at Microsoft.Dynamics.Nav.Runtime.NavSqlTenantPropertiesSync.Upgrade(NavSqlConnectionScope conScope) at Microsoft.Dynamics.Nav.Runtime.NavSqlTenantPropertiesSync.Sync() at Microsoft.Dynamics.Nav.Runtime.NavSqlDatabaseSync.SynchronizeTenantDatabase(NavSession session, SynchronizationSetup syncSetup, Boolean sortingPropertiesDifferent)
I assume that it is best to raise a support ticket via your CSP.
Thanks Marco. We are sending the support ticket.
Please do share final outcome if possible.
I have the same issue when upgrading from 15.2 to 16.3
So please post the solution if you have it. Thank You
Microsoft support provided the possible solutions but it does not resolved the error.
So, we ended up analyzing the tables and debugging.
Here are the steps we did:
1. DELETE FROM dbo.$ndo$navappschemasnapshot WHERE [istableextension] = 1 and originalobjectid = <custom object ID range>
2. Run Sync-NAVTenant. In our case, we still getting the error
3. Drop all tables with $AppData. Not sure why these tables exists after converted from 15.2 to 16.1. We found these tables exists in some ways but from other databases that we converted it doesn't.
4. Run Sync-NAVTenant again.
We solved our issue for these steps.
Hope this will help
Thank you for sharing this solution.
Dropping the $AppData tables made that I could execute Sync-NavTenant succesfully
Thank you for sharing final outcome with the community.
Business Applications communities