SQL Server 2012

こ雲淡風輕ζ 提交于 2019-12-01 19:55:22

问题


Is there a way to export DDL for SQL Server 2012?

A previous question of this nature was answered in Dec 2009, but it does not seem to apply, Previous answer: For SQL Server:

In SQL Server Management Studio, right click on your database and choose 'Tasks' -> 'Generate Scripts'.

You will be asked to choose which DDL objects to include in your script. link edited Dec 19 '09 at 8:58

answered Dec 18 '09 at 18:53 Daniel Vassallo 78.6k11129180

I've tried the suggestion, but after right-clicking on my database, these is no such "Tasks" option.

Any ideas?

2012 Analysis Services just has a deployment wizard. I'm not deploying, just trying to document. I've checked Data Quality Services, Integration Services, Performance Tools, but do not see anything that I recognize.

I've been working with SQL Devloper for Oracel for the past few years, but I seem to remember ACCESS and SQL Serever management had a Data Export on the Tools menu. It allowed you to pick and choose what to export, including DDl, with or without data.

I'd like to do something like that - include all my tables, but no data.

Any ideas?

Thanks.


回答1:


I assume you want to script the DDL from a particular database on your SQL Server 2012 instance. To do so you click on the database of interest in SSMS, then right click and then hover over 'Tasks >', and then across and down to click on 'Generate Scripts'. This will open the wizard as shown in the three screen shots below. Tip: Be sure to check out the scripting options on the 'Advanced' tab.



来源:https://stackoverflow.com/questions/11365228/sql-server-2012

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!