Script the trustworthy flag for each database

Assuming we are building a new server and restoring .. script out the Trustworthy flag and set it.

Id #45 | Release: None | Updated: Apr 9 at 8:48 PM by billgraziano | Created: Apr 9 at 8:48 PM by billgraziano

Script the database owner

Need a way to script the database owner.

Id #44 | Release: None | Updated: Apr 9 at 8:47 PM by billgraziano | Created: Apr 9 at 8:47 PM by billgraziano

Script server permissions

Such as grant view server state to User1; grant view database state to User1; grant select on sys.dm_db_index_usage_stats to User1;

Id #43 | Release: None | Updated: Mar 26 at 2:47 PM by billgraziano | Created: Mar 26 at 2:47 PM by billgraziano

Scripted Jobs need a GO

When all jobs are scripted to one file they aren't separated by a GO statement.

Id #42 | Release: None | Updated: Mar 26 at 2:37 PM by billgraziano | Created: Mar 26 at 2:37 PM by billgraziano

Script database event notifications

Script database event notifications

Id #33 | Release: None | Updated: Oct 9, 2012 at 10:59 PM by billgraziano | Created: Oct 9, 2012 at 10:59 PM by billgraziano

Script out database properties

If I'm scripting a database, run the .Script() method on the database itself so that we capture all it's properties.

Id #27 | Release: None | Updated: Dec 27, 2012 at 2:03 PM by billgraziano | Created: May 27, 2012 at 9:18 PM by billgraziano

Include the instance name at the top of each script

Include the instance name at the top of each script

Id #22 | Release: None | Updated: May 6, 2012 at 5:42 PM by billgraziano | Created: May 4, 2012 at 6:38 PM by billgraziano

Catch a server not found error

Catch and handle this error. Also consider reducing the timeout.

Id #20 | Release: None | Updated: Jul 23, 2012 at 3:26 PM by EddyW | Created: Apr 6, 2012 at 7:16 PM by billgraziano

Don't script job schedule GUIDs

Scripts for jobs contain "@schedule_uid=N'c8576cb9-a455-4894-9ad6-b1734d004d67'" row (example) which should be just omitted - job scheduling GUIDs are usually different between servers unless you r...

Id #13 | Release: None | Updated: Jul 23, 2012 at 3:25 PM by EddyW | Created: Dec 28, 2011 at 7:28 PM by billgraziano

Only list non-standard configuration information

Only report the items where the value is different than the default value. Capture the query from SQL Server 2008 R2 dashboard and mimic it.

Id #10 | Release: None | Updated: Jul 23, 2012 at 3:25 PM by EddyW | Created: Nov 4, 2011 at 5:05 PM by billgraziano