Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

Add a script

<< Newer    Items 81 to 100 of 3339    Older >>
 

Mirror Partner Agent Job To Auto Kick Back to Primary

Query the mirror instance via agent job to auto kick back to primary. If db is in suspended state will resume mirroring.  Read more...
By Ryan Loftin 2016/01/05 | Source: SQLServerCentral.com | Category: mirroring
Rating: |  Discuss |   Briefcase | 409 reads

Fix Orphan Users for Instance Migration

Use provided script to fix orphan users for all databases after Instance Migration. Tested on SQL 2014.  Read more...
By Ajay Dwivedi 2016/01/04 | Source: SQLServerCentral.com | Category: migration
Rating: |  Discuss |   Briefcase | 1,227 reads

Merry Christmas

A holiday decoration for you  Read more...
By Steve Jones 2015/12/25 | Source: SQLServerCentral.com
Rating: |  Discuss |   Briefcase | 1,494 reads

Failed and Successful Login Auditing Using xp_readerrorlog

Script uses undocumented extended stored procedure xp_readerrorlog to find failed logins (grouped) and last successful login  Read more...
By Ryan Loftin 2015/12/30 | Source: SQLServerCentral.com | Category: auditing
Rating: |  Discuss |   Briefcase | 852 reads

Know read and write ratio before you tune database performance

A script to get the user table query ratio and update radio,etc  Read more...
By Michael Zhang 2015/12/21 | Source: SQLServerCentral.com | Category: performance tuning
Rating: |  Discuss |   Briefcase | 1,529 reads

Add empty first step for every job

This script adds empty first step for every job for easier job history viewing.  Read more...
By Alexander Sigachov 2015/12/28 | Source: SQLServerCentral.com | Category: job
Rating: (not yet rated) |  Discuss |   Briefcase | 1,593 reads

Shrink database log file

How to reduce a database log file size? A script and process to help you.  Read more...
Rating: |  Discuss |   Briefcase | 1,786 reads

SQL server Service, Account, Trace Flag info

This script outputs sql server service, start type, status, Service Account, installation location, start up time, uptime of sql server related services along with startup trace flags.   Read more...
By Kin Shah 2015/12/17 | Source: SQLServerCentral.com | Category: sql agent
Rating: |  Discuss |   Briefcase | 948 reads

Find SQL Services and Accounts

Find SQL Services and what account they run under with Powershell  Read more...
By Michael D'Spain 2015/12/18 | Source: SQLServerCentral.com | Category: powershell
Rating: |  Discuss |   Briefcase | 1,046 reads

Script to configure Log File Size for Large DBs

Use this script to set recommended Log files size growth for larger DBs. For more, please refer article: http://sqlmag.com/blog/choosing-default-sizes-your-data-and-log-files  Read more...
By Ajay Dwivedi 2015/12/15 | Source: SQLServerCentral.com | Category: database configuration
Rating: |  Discuss |   Briefcase | 1,109 reads

Check FileSize and LogUsage for all DBs

This script provide informations about SQL DBs files size and Log usage. This little script use os_performance_counters  Read more...
By Jean-François Dann 2015/12/14 | Source: SQLServerCentral.com | Category: database files
Rating: |  Discuss |   Briefcase | 1,402 reads

Orphaned Database Files

A neat way to detect if there are any orphaned SQL database files taking up space on your server.  Read more...
By Geoffrey Woodward 2015/12/08 | Source: SQLServerCentral.com | Category: administration
Rating: |  Discuss |   Briefcase | 1,207 reads

Function for Getting Interval Dates by days,months,years.

Function for Getting Interval Dates by days,months,years for particular week number, for particular month, for particular date between 1 to 31. etc... All in One Date Interval Related Function.  Read more...
By BHAVIN GALA 2016/06/27 | Source: SQLServerCentral.com | Category: date calculations
Rating: |  Discuss |   Briefcase | 1,715 reads

Faster Log Shipping Restores

When you’re reading from a log shipped secondary, you want the duration of restores to be as short as possible. The sproc provided switches the restores to “NORECOVERY” mode, and then switch back to “STANDBY” at the end of the process.   Read more...
By Richie Lee 2015/12/11 | Source: SQLServerCentral.com | Category: log shipping
Rating: (not yet rated) |  Discuss |   Briefcase | 710 reads

Estimate compression for all tables and indexes with both Row and Page

This will log output of estimate compression for both PAGE and ROW for all tables and indexes  Read more...
By Doran Mackay 2015/12/10 | Source: SQLServerCentral.com | Category: compression
Rating: (not yet rated) |  Discuss |   Briefcase | 619 reads

Getting transaction log space usage statistics for all databases.

Easy way to get the TLOg space Usage details  Read more...
By S M 2015/12/07 | Source: SQLServerCentral.com | Category: space usage
Rating: |  Discuss |   Briefcase | 1,159 reads

SQL Jobs on Always On

This script will check the status of the node in Always On and enable or disable the jobs according to our requirement.  Read more...
By Raghavender Chavva 2015/12/02 | Source: SQLServerCentral.com
Rating: |  Discuss |   Briefcase | 1,222 reads

proc to calculate DM_OS_PERFORMANCE_COUNTERS over time interval

This is a stored proc that gives you the calculated performance counters over a time interval you specify.  Read more...
By John Heimiller 2015/12/04 | Source: SQLServerCentral.com | Category: performance
Rating: |  Discuss |   Briefcase | 913 reads

View for Ola Hallengren CommandLog

Add 3 columns, duration in seconds,Pagecount and fragmentation. For people like me who don't enjoy querying XML.  Read more...
By Doran Mackay 2015/12/03 | Source: SQLServerCentral.com
Rating: |  Discuss |   Briefcase | 1,187 reads
<< Newer    Items 81 to 100 of 3339    Older >>