Daily Coping 3 Feb 2023
Today’s coping tip is to ask other people about things they’ve enjoyed recently I asked the question on Twitter and on Facebook, looking for interesting responses from friends. The...
2023-02-03
12 reads
Today’s coping tip is to ask other people about things they’ve enjoyed recently I asked the question on Twitter and on Facebook, looking for interesting responses from friends. The...
2023-02-03
12 reads
I’ve had a goal to redo my demo environments and get them set up to work for a variety of customers in different places. I decided to do this...
2023-02-03 (first published: 2023-01-23)
122 reads
Being more senior in a role can be an advantage if you work at using your extra knowledge.
2023-02-03
145 reads
Today’s coping tip is to challenge negative thoughts and look for the upside. I’m struggling with some negative thoughts outside of work. This year as I coach older girls,...
2023-02-02
15 reads
Today’s coping tip is to decide to lift people up rather than put them down. This is something I am trying to practice more as a coach, pointing out...
2023-02-01
14 reads
The grade for January is a D. Details below, but just not making a lot of progress in these areas. I set goals at the beginning of the year,...
2023-02-01
21 reads
Today’s coping tip is to take a small step towards and important goal. One of my goals this year was to work on a way to score myself with...
2023-01-31
8 reads
In a previous post, I set up the basic databases for the PoC project I’m working on. In this next post, we’ll get the Flyway Desktop projects set up...
2023-01-31 (first published: 2023-01-30)
32 reads
2023-01-30
372 reads
Today’s coping tip is to plan something fun and invite others to join you. The fun thing is actually skiing today. My wife and I wanted to get some...
2023-01-30
15 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