Ensuring SQL Compare Checks Synonyms
I was running a PoC for a customer and they noticed that synonyms were being missed when they changed the database being used. It was surprising to me, but...
2022-04-27 (first published: 2022-04-13)
166 reads
I was running a PoC for a customer and they noticed that synonyms were being missed when they changed the database being used. It was surprising to me, but...
2022-04-27 (first published: 2022-04-13)
166 reads
Had a great time talking with Richard on RunAsRadio about Query Performance Tuning Strategies, check it out. How do you keep your SQL queries fast? Richard chats with Monica...
2022-04-27 (first published: 2022-04-13)
388 reads
Normally I write these posts on a Friday evening. Sometimes it’s later than that, but always before Monday so that my editor can give it some attention before I...
2022-04-27
28 reads
I started to add a daily coping tip to the SQLServerCentral newsletter and to the Community Circle, which is helping me deal with the issues in the world. I’m...
2022-04-26
14 reads
This is video two in a four-part series walking you through how to leverage the Microsoft Graph API within Power Automate. In this video, I
2022-04-26
122 reads
Let’s assume that you started off with the lower editions and capacity with Redis and your developers tell you to scale the Redis cluster. Well first to use a...
2022-04-25
33 reads
Over the next couple days (weeks?), a significant change is coming to my blog (and if you’re reading this text, it’s already happened). I will be leaving Wordpress behind...
2022-04-25
14 reads
I started to add a daily coping tip to the SQLServerCentral newsletter and to the Community Circle, which is helping me deal with the issues in the world. I’m...
2022-04-25
24 reads
I have a database project in Visual Studio. Inside the database, I use a couple of system views to fetch some metadata about tables. To make the project build...
2022-04-25 (first published: 2022-04-16)
521 reads
Today Paul sent out the quarterly numbers to the team letting us know the hours our courses have been viewed during March. Being a data guy, I decided that...
2022-04-25 (first published: 2022-04-12)
427 reads
With Fabric Mirroring, Microsoft is promoting a nice and appealing story for operational reporting...
If you’ve been watching AI roll through the data community and thinking, “this seems...
By Arun Sirpal
Not every production incident is a database in RECOVERY_PENDING or a corrupted event (like...
Comments posted to this topic are about the item SQL Art, Part 4: Happy...
Hi All I am trying to find 'bad' characters that users might type in....
Comments posted to this topic are about the item Extreme DAX: Take your Power...
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