Run the script to see which schemas are available in a database.
[SchemaName] = the schema's name
[SchemaOwner] = authorization specified at creation
[Source] is either User, System, or Fixed Role
eyu27,
2015-07-14 (first published: 2015-06-10)
Run the script to see which schemas are available in a database.
[SchemaName] = the schema's name
[SchemaOwner] = authorization specified at creation
[Source] is either User, System, or Fixed Role
-- Works on MS SQL Server 2005+ SELECT a.name As [SchemaName] -- The schema's name , b.name As [SchemaOwner] -- Set at creation , CASE WHEN a.schema_id <5 THEN 'SYSTEM' WHEN a.schema_id >16000 THEN 'FIXED ROLE' ELSE 'User' END As [Source] -- User or system? FROM sys.schemas a INNER JOIN sys.schemas b ON a.principal_id = b.schema_id ORDER BY [Source] DESC -- Sort 'user' schemas to the top
Andy returns to the Worst Practice series this week with a short article looking at how connection strings in applications affect what you see in sysprocesses. Perhaps less controversial (in our opinion) that some of the other worst practices, this is something easy to fix and definitely worth fixing! Read the article and post a comment - explore other points of view! Readers posting a comment will be entered in a drawing for a copy of the SQL Server 2000 Resource Kit.
2003-08-01
15,714 reads
In this follow up to one of our most popular articles, Andy responds to comments posted by readers and discusses how to manage SQL logins effectively in your applications.
2002-08-19
6,807 reads
Andy says Windows Authentication "is bad". What? That's not what Microsoft says! Heck, that's not even what we say! Everyone knows NT authentication is the way to go. Then again, when was the last time Andy wrote an article that wasn't worth reading?! Read the article, rate it and add a comment - and automatically be entered in a drawing for a copy of SQL Server 2000 Performance Tuning donated by Microsoft Press.
2002-06-25
12,631 reads
In this follow up article Andy looks at how maintenance plans report errors and how they actually accomplish what they do. A little snooping with Profiler reveals all!
2002-05-21
9,277 reads
In this article, Brian looks at how Citrix MetaFrame can use SQL Server for its internal data repository. The basic operation of SQL Server in a Citrix MetaFrame installation is covered. In addition, Brian looks at how a DBA is an integral part of the support team for a successful Citrix MetaFrame farm.
2007-03-02 (first published: 2002-05-13)
26,549 reads