script all objects of a database in sql server

Scripting all objects of a database in SQL Server can be done easily by right clicking on the database and to go Tasks -> Generate Scripts.

This will show up a dialog box which will allow you to script all or selected objects (schema, stored procedures, tables, users and views) with specific options.

Advertisements