Create programmatic classes of the first model from the existing database

I looked at the EdmGen.exe file, but it doesn't seem to support generating the first code model classes from an existing database. Everywhere I look, I am told that I am using a wizard in Visual Studio, but I am trying to automate this process. Is there a command line tool I can use to generate the first code model classes and context class from an existing database? I want this to be part of my continuous integration process, so it should be fully automated.

+3


source to share


1 answer


I don't know of any command line tool that does what you ask, but it is possible to create a custom tool that uses schema views to generate code.

For example, you should use a view sys.objects

to get classes and a view sys.columns

to get fields in those classes.



https://msdn.microsoft.com/en-us/library/ms190324.aspx

0


source







All Articles