- Click on database. Right click on database and open context menu.Select Tasks > Generate Scripts... from displayed menu.
- Microsoft SQL Server 2011 Generate and Publish Scripts wizard is displayed. Click on Next buton.
- We are going to choose database objects that we want to create scripts for. If you want to script data of a single sql table, choose the "Select specific database objects" option. If you want to generate script for all database objects in the target database you can choose "Script entire database and all database objects". Click on Next button
- Next we will configure scripts in detail and save or publish options.If you want to display the generated data script in the SQL Server Management Studio Query Editor window.
- The most important configuration here in this screen is configuring the script wizard to script data. So please click Advanced buton. In the Advanced Scripting Options configuration screen, find Types of data to script parameter. The default selection is Schema only script type. In order to script data in table in SQL Server, you can either choose Data only script type or Schema and data script type.
- After you completed your advanced scripting options selection, click OK buton. Then click Next buton. Click Next buton if everything is correct. Or click Previous buton to reconfigure generate script data options.
- The Generate and Publish Scripts wizard, executes the task and displays each step and the result of the task execution.
- Click Finish buton to close the SQL Server 2011 generate script wizard.
Tuesday, 22 March 2011
How to Generate the Scripts for Table with data in sql server 2011
Steps requied to generate Script in MS-Sql Server 2011:
Labels:
Sql Server
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment