views:

1279

answers:

2

I see that EF can update a model based on an existing database schema. However, I'm starting totally from scratch; I don't want to build tables, then rebuild them in the EF model file. Is there a way that I can draw out a model file, and have the SQL tables automatically be created for me?

+3  A: 

Unfortunately, you have to wait for version 2 of EF.

Here is a link to the EF team's blog, where they talk about adding Model First support in v2:

One of the most painful omissions from the Entity Framework V1 was Model First, which basically means creating a conceptual 'model first' and then deriving a storage model, database and mappings from that.

[...]

The next release of the Entity Framework will include the ability to generate database schemas from your model. The main entry point into this feature is via the Designer context menu, to which we will add a new option called “Create Database from Model”.

Erik Öjebo
A: 

Is it possible in any way to just update the database schema from entity model..? So that all the information in the database stays in the database? When you generate database from model the information will get lost.. It's so frustrating.. I work against SQL Azure, and I have not found any tool to manage the tables and realtions in the SQL Azure database in a proper way.. It would be soo nice if it could be done by the Entity Framework designer.

Mattias Engman
You should ask this as new question and just provide this question as background if you think it's helpful for the context of yours.
Burly

related questions