Use The Correct Data Type
Blog post #5 in support of Tim Ford’s (b|t) #iwanttohelp, #entrylevel. Read about it here.
Saying that you should use the...
2016-05-18 (first published: 2016-05-12)
1,992 reads
Blog post #5 in support of Tim Ford’s (b|t) #iwanttohelp, #entrylevel. Read about it here.
Saying that you should use the...
2016-05-18 (first published: 2016-05-12)
1,992 reads
Letting SQL Server change data types automatically can seriously impact performance in a negative way. Because a calculation has to be run...
2016-05-03
611 reads
August two years ago I originally posted, Make the PASS Summit Work for Your Employer. After conversations at several SQL...
2016-05-02
977 reads
Not all of us are going to use Azure in the same way. That’s just common sense. Therefore, not all...
2016-04-27
1,841 reads
For several years, many of us who were involved with working in Azure from the early days, were concerned that...
2016-04-21
534 reads
If you read the March PASS Board meeting minutes, you saw that there was a discussion around board members and...
2016-04-20
492 reads
Blog post #4 in support of Tim Ford’s (b|t) #iwanttohelp, #entrylevel
In SQL Server, in the T-SQL you use to query...
2016-04-19 (first published: 2016-04-12)
3,133 reads
I’ve been getting lots of questions on views lately. Must be something in the water.
Because SQL Server allows you to...
2016-04-05
558 reads
THIS IS NOT AN APRIL FOOL POST!
Seriously.
My Speaker of the Month for April 2016 is Keith Tate (b|t) and his...
2016-04-01
493 reads
I offer instruction on the Azure Data Platform, and have for about six years, since shortly after it came out....
2016-03-29
821 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