✅ Visual Studio SSMS error An item with with the same key has already been added
So I am following a tutorial of Model First Approach in ASP.NET MVC in which I am using ADO.NET Entity Model Data, Empty EF Designer model and when generating the database after defining it's properties getting an error of An Item with the same key has already been added.
Here's my Model and the error while generating DDL is An item with the same key name is already added.
5 Replies
are you required to use this old stuff? ADO.NET and EF don't mix (no reason to use raw ADO.NET if you're using EF), and EF Designer looks like an EF6 thing which is an old version of EF
If you have no further questions, please use /close to mark the forum thread as answered
Okay Thank you
But do you know any fix to this error?
Like I am creating a model then generating ddl from it but I don't know the reason behind this error, have searched everywhere on the internet.
no, i don't use these tools because they're more or less obsolete
Okay no issues. Thank you