This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/************************ | |
Script Purpose: To Keep Database Restore Log | |
Script By : Aasim Abdullah for https://connectsql.blogspot.com | |
************************/ | |
USE master | |
GO | |
CREATE TABLE DatabaseRestoreLog | |
(DatabaseName VARCHAR(50), RestoreDate DATETIME, RestoredFrom VARCHAR(500)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Tables Relationship Script | |
-- Script By: Syed Muhammad Yasir for http://connectsql.blogspot.com | |
-- Updated August 1, 2012 | |
-- | |
SELECT CASE WHEN a.parent_object_id IS NULL | |
THEN parent.name + '-1--*-' + child.name | |
ELSE parent.name + '-1--1-' + child.name | |
END AS TablesWithRelations |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Script to send an alert through mail, with information that how many drive | |
space is required from next databases growth on a specific instance and how many | |
space is available. | |
Script By: Amna Asif for ConnectSQL.blogspot.com | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
USE master | |
GO | |
-- Create table to hold valid IP values | |
CREATE TABLE ValidIPAddress (IP NVARCHAR(15) | |
CONSTRAINT PK_ValidAddress PRIMARY KEY) | |
-- Declare local machine as valid one | |
INSERT INTO ValidIPAddress | |
SELECT '<local machine>' |
NewerOlder