sql server - How can I save the schema of a SQL Database to a file? -


I am writing a software application in C #. Net, which connects to a SQL Server database My C # project is in the SVN version control, but I would like to include my database schema in the SVN repository. It was suggested to archive the scripts to generate a database in version control. Is there a way to automatically generate these scripts from an existing database?

I am very new to SQL Server, but I saw in the management studio that the SQL command can automatically generate the right to create a table, clicking on the table and clicking on "Script Table As" Is there an equivalent command that will work with the whole database?

You can use or script out, or products like (if you have multiple dependencies , So you want to use a mature third party tool like this).


Comments