Early Bird Pricing for the Data Community Summit Ends Jul 26
The early bird pricing for the PASS Data Community Summit ends this week, on Jul 26. After that, there is a bump, so let you boss know this is...
2023-07-24
35 reads
The early bird pricing for the PASS Data Community Summit ends this week, on Jul 26. After that, there is a bump, so let you boss know this is...
2023-07-24
35 reads
What will be much easier with Microsoft Fabric?
Microsoft Fabric is built on a foundation of Software as a Service (SaaS), which takes simplicity and integration to a whole new...
2023-07-24 (first published: 2023-07-11)
401 reads
Just to reiterate what's in the title of this post, what I mean is that the CLUSTERED COLUMNSTORE indexes are not ordered, while NONCLUSTERED COLUMNSTORE created indexes are on...
2023-07-24 (first published: 2023-07-05)
538 reads
I am so happy to announce that I have joined the team at Fortified Data. I have just completed my first week (well, four days) and I feel like...
2023-07-23
40 reads
Looking forward to #jambalaya at #SQLSatBR on July 29! Register today: sqlsatbr.comI hope to see as many people as possible that weekend, I'll be there at the Friday night...
2023-07-22 (first published: 2023-07-21)
32 reads
Ozurie – feeling torn between the life you want and the life you have. I think many people feel ozurie often. I certainly had a lot of this in...
2023-07-21
385 reads
Quick notes on the event this year: Overall a good event and now I have a few months until SQLSaturday in Orlando in October.
2023-07-21 (first published: 2023-07-06)
164 reads
I’ve mentioned previously how not having up to date statistics can cause problems in query performance. This post looks at something called the Ascending Key Problem which can badly...
2023-07-21
124 reads
I give a few talks on career topics, and one of these is Branding Yourself for a Dream Job. In the talk, I sometimes tell a story in the...
2023-07-21 (first published: 2023-07-10)
195 reads
A while back I talked about the fact that you can grant someone CREATE PROCEDURE and ALTER on a schema ... Continue reading
2023-07-20
62 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