New Azure VMs that perform close to on-prem servers?!
Working with large databases, multi-terabyte in size, I've had clients who have wanted to move to the cloud. However, after testing and...
2025-06-12
5 reads
Working with large databases, multi-terabyte in size, I've had clients who have wanted to move to the cloud. However, after testing and...
2025-06-12
5 reads
🌟 Why Microsoft Azure Certifications Are Beneficial for Your Career 🗓️ How to Schedule and Appear for Azure Certification Exams Microsoft Azure Certification Corporate Discounts: How to Save Up...
2025-06-12
63 reads
I’m presenting a free webinar at MSSQLTips.com at Thursday, July 10, 2025 at 6PM UTC (8PM CET or 2PM EDT). The abstract: As you might learn from the abstract,...
2025-06-11
66 reads
I had someone ask me about using triggers to detect changes in their tables. This is a second post looking at triggers, in this case, modifying my trigger to...
2025-06-11
78 reads
I’m working on an update to my Query Performance Tuning book for SQL Server 2025 and I found myself wondering, will a query hint be immediately apparent in an...
2025-06-11 (first published: 2025-05-26)
496 reads
If your SQL Server has both SQL and Windows logins and you’re not sure why, you’re not alone. Many IT teams without a dedicated DBA bump into this sooner...
2025-06-11 (first published: 2025-05-21)
519 reads
This month we have a great invite from Joe Fleming, a first time host of T-SQL Tuesday. Joe reached out when I requested some hosts and I’m glad he...
2025-06-10
104 reads
The crime spree in Digitown is not ending. This time 20 cars have been stolen and we need to find where they’re stored.
The problem
This is the abridged case description....
2025-06-09 (first published: 2025-05-16)
281 reads
One of the biggest challenges with monitoring data is managing the volume over time. Lots of bespoke/home-grown solutions don’t do this well, and some commercial products have a gross...
2025-06-09
36 reads
With the release of SQL Server 2025, Microsoft is firmly positioning its flagship database platform as an enterprise-ready AI solution. Having spent time with the preview builds and working...
2025-06-09 (first published: 2025-05-19)
535 reads
It is Friday, the queries are running, and nobody is watching the bill. That...
By Steve Jones
Annabel retired from Redgate Software this week. Across most of my career at Redgate,...
By Tim Radney
As a SQL Server DBA with years of experience tuning production environments, I’ve seen...
Comments posted to this topic are about the item What is the Cloud?
Comments posted to this topic are about the item Changing the Schema
Comments posted to this topic are about the item Index Fragmentation Explained: Page Splits,...
I set up a few users on my SQL Server 2022 instance.
CREATE LOGIN User1 WITH PASSWORD = 'Demo12#1' CREATE USER User1 FOR LOGIN User1 GO CREATE LOGIN User2 WITH PASSWORD = 'Demo12#2' CREATE USER User2 FOR LOGIN User2 GO CREATE LOGIN User3 WITH PASSWORD = 'Demo12#3' CREATE USER User3 FOR LOGIN User3 GOI then created a schema that one of them owned. Under this schema, I added a table with some data.
CREATE SCHEMA MySchema AUTHORIZATION User1
GO
CREATE TABLE Myschema.MyTable(myid INT)
GO
INSERT MySchema.MyTable
(
myid
)
VALUES
(1), (2), (3)
GO
SELECT * FROM MySchema.MyTable
GO
I granted rights and verified that User2 could access this table.
GRANT SELECT ON Myschema.MyTable TO User2 GO SETUSER 'USER2' GO SELECT * FROM MySchema.MyTable GOThis worked. Now, I move this schema to a new user.
ALTER AUTHORIZATION ON SCHEMA::Myschema TO User3; GOWhat happens with this code?
SETUSER 'USER2' GO SELECT * FROM MySchema.MyTable GOSee possible answers