Choosing to not drive the Tesla
I started a short thread on Twitter/X and Bluesky recently after leaving the Tesla at home recently. A few people asked me about it, so I decided to do...
2025-02-14
39 reads
I started a short thread on Twitter/X and Bluesky recently after leaving the Tesla at home recently. A few people asked me about it, so I decided to do...
2025-02-14
39 reads
Juggling meetings, deadlines, and family? Yeah, learning SQL might seem like climbing Mount Everest in flip-flops. But guess what? You absolutely can become an SQL whiz without sacrificing your...
2025-02-14 (first published: 2025-02-05)
747 reads
Hey data friends! This one comes from my personal vault (aka backlog of drafts I’ve been needing to write up) and is a really simple code that I always...
2025-02-14 (first published: 2025-01-28)
1,297 reads
Introduction Growing enterprises or businesses that want to remain competitive must make quick decisions daily. While experience and expertise are essential in that process, making those critical calls is...
2025-02-14
11 reads
Introduction Building a practical data governance framework can feel like building a house: you need a strong foundation, reliable materials, and the right team to make it all work. Data governance is crucial for organizations to manage, protect, and utilize their data effectively. A well-defined framework...
2025-02-13
17 reads
You can’t just exec DROP ROLE your_role_name; if it’s granted perms or other roles are granted to it. I had to go fishing to find all the grants to...
2025-02-12 (first published: 2025-01-27)
238 reads
Straight from Microsoft’s documentation “Microsoft Entra authentication is a mechanism of connecting to Azure Database for PostgreSQL flexible server by using identities defined in Microsoft Entra ID. With Microsoft...
2025-02-12 (first published: 2025-02-03)
279 reads
I have a few clients that incrementally load tables from a SQL Server source into their data warehouse or lakehouse by using change tracking. Lately, they encountered some issues...
2025-02-10 (first published: 2025-01-31)
277 reads
Over the years I’ve been called in to work with numerous clients that were hit with ransomware. Even the times that the customer paid the ransom to unlock their...
2025-02-10
27 reads
This is more complicated than using the Azure Migration method, but because it’s maxed out on resources for the last week in the east regions (and possibly central), and...
2025-02-10 (first published: 2025-02-09)
72 reads
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...
It is Friday, the queries are running, and nobody is watching the bill. That...
Comments posted to this topic are about the item SQL Art, Part 4: Happy...
WhatsApp: 0817839777 Kw. Industri Pulogadung, Jl. Raya Bekasi Km. 21, Ruko No.A2/18-19, RW.3, Wil,...
WhatsApp: 0817839777 Jl. I Gusti Ngurah Rai No.8 A-B, RT.8/RW.6, Wil, Kec. Duren Sawit,...
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