1

In SQL Server 2008 it is possible to script data from SQL Server Management Studio.

I would like to make a job, that scripts everything in my database (tables, stored procedures etc) to one file and all data in some tables to another.

Is it possible - and what is the easiest way to do it?

The reason why I want this is so I can put my development databases under source control.

2 Answers 2

0

Right click on the database, and select Tasks, then Generate Script. In the wizard on the options page, change Script Data from false to true.

2
  • That is not what I asked. I want to automate it, so I can run it in a scheduler that does what you just described.
    – Kjensen
    Aug 25, 2009 at 22:48
  • There's no native way to script out the database or the data. I'm not sure if the their party tools can be scheduled to do this either.
    – mrdenny
    Aug 26, 2009 at 1:13
0

ScriptDb from Elsasoft does this. It is an open source commandline app from Elsasoft.

1

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .