Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
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

   Items 1 to 20 of 3046    Older >>
 

Querying deadlock graph from SQL Extended Events

Sample script to read deadlock graph XML from default system health XEvent.  Read more...
By Marcelo Fonseca 2014/10/21 | Source: SQLServerCentral.com | Category: xevents
Rating: (not yet rated) |  Discuss |   Briefcase | 498 reads

Retrieve instance-wide index level fill factor information

This script retrieves all fill factor information for all indexes (clustered and non) when it is not set to 0 or 100  Read more...
Rating: (not yet rated) |  Discuss |   Briefcase | 9 reads

Extract SQL Server Key details

Extract SQL Server Name, Instance Name, Service Account details, startMode and ServiceState details with Powershell.  Read more...
By S M 2014/10/13 | Source: SQLServerCentral.com | Category: powershell
Rating: |  Discuss |   Briefcase | 15 reads

Datetime Formats

This stored procedure will show all possible datetime formats when used with the style argument in the CONVERT() function. It also shows sample output from the date part arguments.  Read more...
By Doug Deneau 2014/10/10 | Source: SQLServerCentral.com | Category: datetime
Rating: (not yet rated) |  Discuss |   Briefcase | 19 reads

Split string using multiple delimiters

This script is used to split the string using multiple delimiters  Read more...
Rating: (not yet rated) |  Discuss |   Briefcase | 18 reads

Track database growth 2012/2014

Enhancement to Track database growth By Irwan Tjanterik, 2014/09/23  Read more...
By Paulo Nascimento 2014/10/07 | Source: SQLServerCentral.com | Category: administration
Rating: (not yet rated) |  Discuss |   Briefcase | 16 reads

AlwaysOn Availability Group Read Only Routing Script

Generate read only routing commands  Read more...
By Jeff Reinhard 2014/10/06 | Source: SQLServerCentral.com | Category: alwayson
Rating: (not yet rated) |  Discuss |   Briefcase | 6 reads

Resend failed mail.

Script tries to resend all mails that has failed for the last @DaysBack days, before sending it checks if a copy has already been sent. Modify to fit your purpose...  Read more...
By ludvig.derning 2014/10/06 | Source: SQLServerCentral.com | Category: database mail
Rating: (not yet rated) |  Discuss |   Briefcase | 5 reads

Get month days

Gets the number of days in a month  Read more...
By Igor Micev 2014/10/01 | Source: SQLServerCentral.com | Category: t-sql
Rating: (not yet rated) |  Discuss |   Briefcase | 11 reads

Are my production databases accessible

Script below will provide tool to monitor status of all databases on given SQL server. If database(s) is not accessible for any reason notification is send to DBA.  Read more...
By krystian szczyrba 2014/09/29 | Source: SQLServerCentral.com
Rating: (not yet rated) |  Discuss |   Briefcase | 11 reads

Upload Backup Files to Amazon S3

This script will upload the latest backup files to an AWS S3 bucket  Read more...
By Alex Marsh 2014/09/14 | Source: SQLServerCentral.com | Category: backup
Rating: (not yet rated) |  Discuss |   Briefcase | 2 reads

Remove Pattern Matched Characters

Remove characters matched in a patindex pattern recursively.  Read more...
By Steve Holle 2014/10/16 | Source: SQLServerCentral.com | Category: recursive
Rating: |  Discuss |   Briefcase | 802 reads

Missing indexes in current requests

Script to get any current requests with missing indexes  Read more...
Rating: |  Discuss |   Briefcase | 1,163 reads

AAG DB State Monitoring

This script is to help monitor the AAG DB synchronization status. It sends an HTML formatted email if Synchronization status is not "Synchronized" or "Synchronizing"  Read more...
By Tom Mongold 2014/10/14 | Source: SQLServerCentral.com | Category: aag
Rating: |  Discuss |   Briefcase | 511 reads

move tempdb

For maximum performance, tempdb should be placed on a seperate disk. This script does all the work for you, except the restart!  Read more...
By Wilfred van Dijk 2014/10/13 | Source: SQLServerCentral.com | Category: tempdb
Rating: (not yet rated) |  Discuss |   Briefcase | 812 reads

All datatypes basics in SQL Server 2008R2.

What is completed datatypes in sqlserver and how it works in Real time.  Read more...
Rating: |  Discuss |   Briefcase | 1,087 reads

Find only characters or only integer from alphanumeric value

Extract only integers or characters from alphanumeric :  Read more...
By Vimal Lohani 2014/10/07 | Source: SQLServerCentral.com | Category: t-sql
Rating: |  Discuss |   Briefcase | 1,089 reads

Find Currently Running Query – T-SQL

Following script retrieves the queries currently executing on the server.  Read more...
By Sri Kurra 2014/10/08 | Source: SQLServerCentral.com | Category: performance tuning
Rating: |  Discuss |   Briefcase | 1,563 reads

Index rename to standards

Rename indexes according to pattern: IX_<TableName>_<Col1>_<Col2>.. or AK_<TableName>_<Col1>_<Col2>..  Read more...
By Renato Buda 2014/10/06 | Source: SQLServerCentral.com | Category: index rename
Rating: (not yet rated) |  Discuss |   Briefcase | 758 reads

Script Table AS Select To

It generate Select Query Of a given Database and Table  Read more...
Rating: (not yet rated) |  Discuss |   Briefcase | 7 reads
   Items 1 to 20 of 3046    Older >>