SCRIPT: Find the row count of all tables and views
Today I’m sharing another script that I often find useful – Queries to find the count of rows from tables and...
2012-08-15
15,553 reads
Today I’m sharing another script that I often find useful – Queries to find the count of rows from tables and...
2012-08-15
15,553 reads
Today is T-SQL Tuesday #33 hosted by Mike Fal. The topic is SQL Server – Trick Shots. This assignment involves blogging...
2012-08-14
970 reads
As I started looking over my event calendar, I was amazed at how many events Magenic is sponsoring, hosting or...
2012-08-14
571 reads
It’s Not A Repeat
Speaking at the PASS Summit last year was one of the highlights of my career. I had...
2012-08-14
744 reads
I’ve been reading about wooden hand planes lately (as opposed to hand planes made of metal that plane wood) and...
2012-08-14
896 reads
Modifying the Windows host file can be a great way to ensure that you don’t accidentally modify production while doing...
2012-08-14
1,203 reads
My 2011 version of Live Writer didn’t seem to want to embed a Vimeo video, so I checked for an...
2012-08-14
537 reads
As I blogged about previously, tomorrow (Wednesday) I will be speaking for the PASS Professional Development virtual chapter. My talk will...
2012-08-14
1,141 reads
I’m flying in on Sunday again this year, arriving in time for lunch, and looking forward to the luxury of...
2012-08-14
623 reads
Hello Dear Reader, I came across an interesting discovery about a year ago and realized I’d never written about it. ...
2012-08-14
1,096 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