Change owner on all database objects by stored procedure

Another handy dandy script:  http://codebetter.com/blogs/darrell.norton/archive/2004/06/18/16932.aspx Darrell Norton (MVP) has a script that will allow you change the database owner on all of your databases/objects – super helper script! IF EXISTS (SELECT * FROM sysobjects WHERE id = object_id(N'[dbo].[ChangeAllObjectOwnersToDBO]’) AND OBJECTPROPERTY(id, N’IsProcedure’) = 1) DROP procedure [dbo].[ChangeAllObjectOwnersToDBO] GO SET QUOTED_IDENTIFIER OFF    SET ANSI_NULLS  ON GO…


Earliest date known to mankind

Okay… maybe not mankind – but it is the earliest date SQL Server will except for a SQL Date. 01/01/1753


Date and Time in a SQL Statement (DateTime)

To get the date and time for a datetime value in SQL Server, use the GetDate method.  It will return the current system date and time in the SQL Server standard internal format for datetime values. This is a pretty useful function if you need to know the date/time in a select statement or a…