Azure DB for MySQL – server parameters
If you have used MySQL before you will know about the system server variables, you know such commands as SHOW VARIABLES; You can access most of them via the...
2022-02-10
56 reads
If you have used MySQL before you will know about the system server variables, you know such commands as SHOW VARIABLES; You can access most of them via the...
2022-02-10
56 reads
When it comes to MySQL and storage you will normally have to decide on 3 options: basic, general purpose v1 or v2. Basic does support up to 1TB and...
2022-02-07
20 reads
We have already created the server now it’s time to connect to it. What you will need – connection string details, correct networking setup and a tool like MySQL...
2022-02-03
24 reads
Enough of the theory and text lets use the Azure Portal and create MySQL Single server. Navigate to the Azure Portal, find Azure Database for MySQL servers: Click create...
2022-01-31
41 reads
When you start the build process for MySQL you will be shown the below screen, the question is what option would you select? It really does depend; I don’t...
2022-01-19
391 reads
SQL Server is not the only database you build and deploy into Azure. Another very popular option is MySQL. Going back many years, this was actually my first database...
2022-01-11
66 reads
This is our current setup shown below. There is not much to failing over with Managed Instances, from experience it is similar to that of Azure SQL Database. Let’s...
2021-12-17 (first published: 2021-12-07)
277 reads
There is a setting / feature in Managed Instance worth talking about, it is called SQL Trust Groups. What is this? At a basic level it’s a way to...
2021-12-15
114 reads
Lets summarise some important learnings about SQL MI and failover groups. when you add a database to a failover group the secondary database has the same edition / compute...
2021-12-09
142 reads
If you have been following me for a while you will know that I really like the Fail over groups within Azure SQL DB and it is no different...
2021-11-22
26 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