I have an .edmx diagram, EF 6, sometimes when I update from database it just generates the Context.cs file empty and no class at all! We work in different teams so not always I can know exaclty what tables were updated.
Is there any error log I can use to sort this out? How can I debug and fix this issue when EF is in a bad mood?
Ok I found a way around it.
You have to delete on the diagram one by one and save each time you delete an entity. When the buggy entity is discarded it will generate the classes again. At this moment you Update From Database and it updates everything nicely.
-- Update 10/12/20 --
Thanks to Dimitar that pointed out it could be confusing the deleting part: you don't need to delete all entities, just the problematic one (if you know which one it is). The approach to delete entities one by one is to find the problematic one.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With