2018-08-24 (first published: 2014-06-17)
729 reads
2018-08-24 (first published: 2014-06-17)
729 reads
Dynamic SQL can be used to generate a database snapshot. Useful for a database with a number of files.
2018-08-23 (first published: 2016-11-04)
3,596 reads
2018-08-13 (first published: 2018-07-18)
722 reads
2018-08-08 (first published: 2018-07-22)
464 reads
A quick script that provides the sizes of the tables in your database, including schema and choice of sort method
2018-08-07 (first published: 2018-07-29)
850 reads
2018-07-17 (first published: 2018-06-26)
946 reads
SQL Functions that simplify search and operations over strings on SQL Server (starting with 2012)
2018-07-11 (first published: 2018-07-06)
4,962 reads
This script is intended to demonstrate how we can create a stored procedure for the user responsible for backing up user databases in a default storage location.
2018-07-10 (first published: 2018-07-05)
560 reads
2018-07-09 (first published: 2018-07-04)
549 reads
The T-SQL script created a databases using the default file locations from SQL server configuration and prints them in the end.
2018-07-05 (first published: 2018-06-28)
1,984 reads
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...
By ReviewMyDB
Part 1 of my What's New in SQL Server for the Developer series. IIF,...
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...
Comments posted to this topic are about the item Data Lost in the Cloud
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