Sapere aude!

Tags: t-sql

SQLExamples: Common Solutions for T-SQL Problems

Permalink 2008-04-30 09:36, by Torsten Schüßler, Categories: SQL, TSQL , Tags: t-sql
There is a new great WIKI ressource for common T-SQL solutions at MSDN Code Gallery, it's called SQLExampels. In this WIKI presented information, represents the suggestions, ideas, and opinions of Volunteer Moderators and Answerers (you know Arnie Roland… more »

Orphan SQL-Server accounts

Permalink 2008-04-18 14:20, by Torsten Schüßler, Categories: SQL, SQL-Server 2005, TSQL , Tags: t-sql
By using SP_MSForEachDB you can detect and display orphan SQL-Server accounts from all the databases of your SQL-Server. EXEC SP_MSForEachDB 'USE [?]; -- SYSTEM DATABASE ARE EXCLUDED IF DB_ID(''?'') > 4 SELECT ''?'' as DBName, name… more »

Determine the last change of the sa password?

Permalink 2008-04-04 13:15, by Torsten Schüßler, Categories: SQL-Server 2005, TSQL , Tags: sql security, t-sql
Let us face it, when did you last change the sa password? You can check last change in SQL Server 2005, for the sa login by using LOGINPROPERTY function. Execute the following T-SQL code: SELECT LOGINPROPERTY ('sa', 'PasswordLastSetTime') And a little… more »