Error upgrading from BC14 to BC24

apquintas
Member Posts: 7
When following this guide from Microsoft
https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/upgrade/upgrade-unmodified-application-v14-v24
we're getting an error in Task 10, step 1
«Upgrade the data to the platform, system application, and base application.
To run the data upgrade, use the Start-NavDataUpgrade cmdlet:»
running this command
Start-NAVDataUpgrade -ServerInstance $BcServerInstance_24 -Tenant default -FunctionExecutionMode Serial -SkipAppVersionCheck
the DataUpgrade is never complete

and in Event Viewer this is what we get as info...
« An item with the same key has already been added. Key: 00000000-0000-0000-0000-000000000000 »


Anyone has any idea what could generate this kind of error?
would really appreciate some help in this matter..
https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/upgrade/upgrade-unmodified-application-v14-v24
we're getting an error in Task 10, step 1
«Upgrade the data to the platform, system application, and base application.
To run the data upgrade, use the Start-NavDataUpgrade cmdlet:»
running this command
Start-NAVDataUpgrade -ServerInstance $BcServerInstance_24 -Tenant default -FunctionExecutionMode Serial -SkipAppVersionCheck
the DataUpgrade is never complete

and in Event Viewer this is what we get as info...
« An item with the same key has already been added. Key: 00000000-0000-0000-0000-000000000000 »


Anyone has any idea what could generate this kind of error?
would really appreciate some help in this matter..
0
Answers
-
0
-
Hi @GOCEI
Actually Yes!
The problem was related with previous steps upgrading from 2017 to BC14.
In BC14 in Company Table, there is a new GUID field that was populated in both (we had only 2) companies with the value 000000... (see screenshot below)
Solution in our case: Generate 2 new GUIDs and change the field values in the table with Microsoft SQL Server Management Studio (running the table and changing with windows client was not possible although the field was editable)
https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.utility/new-guid?view=powershell-7.4
After that we could finish the script and upgrade from BC14 to BC240 -
hi @apquintas ,
Wow, it worked, i had some records with value 0000... I generated guid for those records and no errors!!!
How did you find out the solution? Because I spent plenty of time trying to solve it and I didnt find any reference to Company Table.
Thanks!!0 -
Hi @GOCEI
I also spent a lot of time with no clue until an ex-colleague with experience in migrations told me that, although he never saw the exact same error, it sounded like the routine was trying to insert a 2nd record with a GUID 00000000-0000-0000-0000-000000000000 but there was already one in the target table.
Then I looked with more attention to the Error in event viewer and saw something related with company before the error message:
« An item with the same key has already been added. Key: 00000000-0000-0000-0000-000000000000 »
(althoug here the picture has no quality you can probably understand the word company 4 and 5 lines below the selected error text)
https://us.v-cdn.net/5022383/uploads/editor/4m/m1p2ursntq8u.png
So then, in Microsoft SQL Server Management Studio, I filtered the tables that contain word "Company" looking for a GUID field.
And that's how I found that one table with the 00000000-0000-0000-0000-000000000000 value repeated in both records
0 -
Hi @apquintas ,
Yeah, I checked en Event Viewer but unluckly I didnt reacht out any proper conclusion.
I was so close to split the upgrade in two, first into the bc22 and later to bc24, it would have been a real pain in the b****s.0 -
[Topic moved from 'General Chat' forum to 'NAV Three Tier' forum]
Regards,Alain Krikilion
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions