SQLServerCentral Article

Review: MyLittleAdmin

SQL Server has great client side tools, Query Analyzer, Enterprise Manager, for working with your server and managing it. But how many times have you wished for a web interface because you didn't have VPN or didn't want to give rights to a developer. Or maybe you host clients' databases on your server and don't want one person to see another's databases. Read this review by someone who actually uses this product.

SQLServerCentral Article

SQL Server Alerts

SQL Server Alerts provide a great way for the server to notify a DBA that some event has occurred, usually something bad that they need to fix. However alerts can also be used to drive business logic processes and enable some types of actions to be safely performed without requiring extraordinary rights by a user. Author Leo Peysakhovich brings us some ideas on how we can use alerts to implement business logic processing.

SQLServerCentral Article

PASS Summit 2004

The 2004 premier SQL Server event, the PASS Summit is coming to Orlando in September. Once again we'er working with PASS to sponsor and promote this event. Read Steve Jones' take on this event and why it's worth your time and your company's money.

SQLServerCentral Article

ADO.NET - A Data Access Layer

Developing applications for SQL Server usually results in a variety of access methods that the programmers use. A data access layer class, given to the developers, is usually seen as the best practice, but one that isn't usually implemented. In fact, in most software I've built, each developer uses his own method, or may cut and paste from another, but rarely is there a central access class. New Author Patryk Nowakowski brings us his solution using ADO.NET.

SQLServerCentral Article

Using Different Techniques for SQL Server Automation

Automating SQL Server tasks is the sign of an experienced DBA. One who doesn't waste time on repetitive tasks that can be easily setup in a job, task, or some other scheduling process to run when they need to run. Haidong Ji has written a number of articles on how to perform automation and brings us yet another technique. This time he looks at managing your backup files, something that we all need to do, but all too often forget to do.

Blogs

Crawl, Walk, Run with Agentic Development of Power BI Assets

By

If you’ve been watching AI roll through the data community and thinking, “this seems...

How AgentDBA Diagnoses SQL Server Issues Fast

By

Not every production incident is a database in RECOVERY_PENDING or a corrupted event (like...

Five Ways Redshift Serverless Quietly Eats Your Budget

By

It is Friday, the queries are running, and nobody is watching the bill. That...

Read the latest Blogs

Forums

SQL Art, Part 4: Happy 4th of July — A British DBA's Guide to Celebrating a War We Don't Talk About

By Terry Jago

Comments posted to this topic are about the item SQL Art, Part 4: Happy...

Finding 'bad' characters

By Barcelona10

Hi All I am trying to find 'bad' characters that users might type in....

Extreme DAX: Take your Power BI and Fabric analytics skills to the next level

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Extreme DAX: Take your Power...

Visit the forum

Question of the Day

Changing the Schema

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
GO
I 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
GO
This worked. Now, I move this schema to a new user.
ALTER AUTHORIZATION ON SCHEMA::Myschema TO User3;
GO
What happens with this code?
SETUSER 'USER2'
GO
SELECT * FROM MySchema.MyTable
GO

See possible answers