开发者

How to generate inserts?

开发者 https://www.devze.com 2023-02-16 12:04 出处:网络
I have Sq开发者_运维知识库l Server database and i would like to export the data as .sql file. The Generate Script for some reason is ignoring the data.The built in Generate Scripts only create the Sch

I have Sq开发者_运维知识库l Server database and i would like to export the data as .sql file. The Generate Script for some reason is ignoring the data.


The built in Generate Scripts only create the Schema not the Data.

You can use an add on such as SSMS Tools Pack to generate scripts that will populate data and schema.


Have you tried the Database Publishing Wizard?


You could go with this script, which we've had success with (thank you, Narayana). Should you use it, please keep the copyright notice and usage notes with it.

If you need something more robust, then Red Gate's SQL Data Compare will do the trick.


Generate Scripts under the database Tasks in the Object Explorer should work. Could you check that Types of Data to Script is set correctly in the Advanced dialog in the Set Scripting Objects wizard pane, as confusingly it defaults to false and is not very discoverable? (are you using SSMS 2008?)

0

精彩评论

暂无评论...
验证码 换一张
取 消