2011-04-27 (first published: 2011-04-21)
2,765 reads
2011-04-27 (first published: 2011-04-21)
2,765 reads
2011-04-26 (first published: 2011-04-20)
2,691 reads
Execute this script to get information on SQL server, databases, processes, memory, buffer, locks, etc.
2011-04-21 (first published: 2009-09-03)
5,683 reads
Monitoring space in production server is one of the top priority tasks for a DBA. This script will automate it
2011-04-19 (first published: 2009-05-28)
6,145 reads
This script will reindex (online) any index eligible to be reindexed online. Accepts a day of week parameter for full offline reindexing.
2011-04-18 (first published: 2008-10-01)
4,717 reads
Retrieve the charindex of matching string for the desired occurrence
2011-04-13 (first published: 2011-04-06)
1,527 reads
Uses sp_MsForEachDb, locates members in db_datareader with permissions other than Select and Connect.
2011-04-11 (first published: 2011-03-29)
1,109 reads
The script will be helpful to kill all the user sessions before performing the refresh of the database.
2011-04-08 (first published: 2011-03-29)
2,698 reads
converting a date from existing timezone to some different time zone covering multiple location
2011-04-05 (first published: 2011-03-24)
1,213 reads
2011-04-01 (first published: 2008-02-23)
3,856 reads
By Steve Jones
I was experimenting with CHOOSE() recently after I was asked a question. In a...
By DesertDBA
I did not expect 27 responses to my T-SQL Tuesday #204 invitation, but it...
Should you adopt an off-the-shelf AI tool, partner with a specialist, build in-house, or...
Has anyone ever seen this before? I have sysadmin permission on a server. I...
Comments posted to this topic are about the item Switching Schema II
Comments posted to this topic are about the item A Practical Approach to Automating...
I run this query:
SELECT s.name AS schemaname , o.name AS objectname FROM sys.objects o INNER JOIN sys.schemas s ON s.schema_id = o.schema_id WHERE o.name = 'Beer'I get two rows back for the objects, named dbo.beer and etl.beer. Both the tables have identical schemas and are not partitioned. There are 25 rows in dbo.beer and 0 rows in etl.beer. I run this code:
ALTER TABLE dbo.beer switch TO etl.beerWhat happens? See possible answers