From Microsoft SQL Server Management Studio right click on database, a pop up menu will appear. From popup menu select tasks > Generate Scripts. A new dialog box called Generate and Publish Scripts window will appear. This window will look like below picture.
From this window click on next button. Choose Objects option will appear like below picture.
Now you can either generate script for all database objects or specific object. To do this just select one option. If you select “Select specific database objects” then you have to select the objects from list.
Now click on next button. Set scripting options will appear like below picture.
We will save the script to a specific location, that’s way select first option. choose the file name. Now click on Advanced button. A new window will appear like below picture.
select “schema and data” option of Types of data to script. This will generate the schema as well data. Click on OK button. Click on next button and review your selection. Then once again click on next button and it will start to generate the script. After generate script just click on Finish button.
Job done.
The post Generate script from Microsoft SQL Server Management Studio appeared first on crea8ivecode.