Building Something Fun - 2
Last Friday I posted about turning my first pen on a lathe, this week I'm discussing my other recent project,...
2009-04-30
1,740 reads
Last Friday I posted about turning my first pen on a lathe, this week I'm discussing my other recent project,...
2009-04-30
1,740 reads
I serve on the PASS Board of Directors, but this post reflects my personal views and not an official PASS...
2009-04-30
1,428 reads
I've written quite a few posts lately on networking and a very common question is - where's the results? What do I get out of all the effort, and so far my best (if lame) answer is that networking is an investment based on faith that...
2009-04-30
1,511 reads
My friend Brian Knight is leading the 2nd annual SQLSaturday in Jacksonville on May 2nd. Right now it looks like...
2009-04-29
1,327 reads
Learn how to get started integrating mail with your SQL Server in this SQL School video. MVP Andy Warren shows how to set up Database Mail.
2009-04-28
5,247 reads
If you haven't already, start with Part 1 and Part 2. In Part 2 I mentioned that I have hired...
2009-04-28
1,415 reads
A week or so ago I posted a note about reading How to Start a Conversation and Make Friends (worth reading), and I had a comment posted to the blog by author Don Gabor. I like that kind of follow up, so I sent Don a note and a ...
2009-04-28
1,528 reads
I saw this post about Why I Dislike Newsgroups from Tom Larock and he did a pretty good job of...
2009-04-27
1,033 reads
I drove up on Friday with my friend Kendal Van Dyke. Long drive from Orlando, just over 8 hours. Arrived...
2009-04-27
663 reads
I'm going to West Palm Beach on Apr 29th to visit Scott Klein and his group. I'll be doing a...
2009-04-26
628 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...
Because we are NABL Accredited Laboratories, our personal care and cosmetics research center provides...
WhatsApp:0817-866-887 Jl. Ahmad Yani No.31, Pattunuang, Kec. Wajo, Kota Makassar, Sulawesi Selatan 90174 (@bcakcumakassar)
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