Updated Overlapping Statistics Scripts
Last year I published a script for identifying automatically generated column statistics that overlapped index statistics. I've updated the script...
2011-04-05
1,697 reads
Last year I published a script for identifying automatically generated column statistics that overlapped index statistics. I've updated the script...
2011-04-05
1,697 reads
Replication: It's Not Really As Bad As SQLRockStar Says It Is
(Wondering what the heck this is supposed to be about?...
2011-04-04
397 reads
Recently there have been a number of PASS members who have become unhappy with the direction of the organization and...
2011-04-01
399 reads
I'm a big proponent of using Virtual Machines for development on your local machine. It just doesn't make sense to...
2011-03-15
612 reads
If you follow me on Twitter or talk to me in person you'll come to realize I'm a space enthusiast....
2011-03-15
514 reads
If you're in the central Florida area you're invited to the March meeting of MagicPASS, South Orlando's SQL Server User...
2011-03-11
483 reads
You've probably noticed I've been quiet on this blog lately, eeking out a post every other week on average. I've...
2011-02-24
1,523 reads
I bet by now you've heard of SQLRally, be it from the blogosphere, Twitter, the PASS Connector bi-weekly emails, word...
2011-02-23
405 reads
If you're in the central Florida area you're invited to the February 2011 meeting of MagicPASS, South Orlando's SQL Server...
2011-02-15
535 reads
On Wednesday, Feb 16th, 3 PM Eastern I'm presenting a webcast for Idera's Secrets of SQL Server series. Presentation details...
2011-02-15
715 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