Wednesday, March 28, 2012

Validate Model

Apparently the 'Validate Model' item of Entity designer context menu, doesn't work (do nothing)

I thought that 'Validate Model' served to check database schema and eventually update mapped entity: so I try to add a new field to a mapped table and tried it, but it doesn't work.

Am I bad thinking ?

Isn't there a similar function ? If not, how can I bring up to date my entities ? I need to recreate the entire model (losing entity modifications) ?

Luca

Hi! Luca,

The "Validate Model" functionality in the designer verifies that that the model and mappings are consistent. For example, it verifies that entities in the conceptual model are correct (e.g. entities have a key, etc) and validates that entities are mapped correctly to the storage model and reports errors in Visual Studio. It does not update the model and mappings to reflect the current state of the database.

We are looking to add some sort of "refresh model from database" functionality in a subsequent release. For this CTP, you can recreate the model & mappings by running the wizard again in a new .edmx file.

Regards,

Sanjay


We are looking to add some sort of "refresh model from database" functionality in a subsequent release. For this CTP, you can recreate the model & mappings by running the wizard again in a new .edmx file.

Therefore abandoning all work accomplished in the designer? For such a highly anticipated release, it is frustrating to me that its still not usable. Doesnt really lend itself to a TDD\Agile environment. Guess its back to hacking the xml files.... sigh.

(I know its a CTP, just dissapointed)

No comments:

Post a Comment