Solved

sysdatabases & user access

Posted on 2010-08-20
3
358 Views
Last Modified: 2012-06-27
is 'mode' have the value for the mode of the database?

http://msdn.microsoft.com/en-us/library/aa260406%28SQL.80%29.aspx
does not tell what it is?

or is there another place to check for SINGLE/MULTI user mode info for SQL 2000?

thanks
0
Comment
Question by:anushahanna
3 Comments
 
LVL 58

Accepted Solution

by:
cyberkiwi earned 275 total points
ID: 33490239
Bitmask 4096 of the status column in the same link

select case when status & 4096 = 4096 then 'Single User' else 'Multi User' end, *
from master..sysdatabases
0
 
LVL 38

Assisted Solution

by:Jim P.
Jim P. earned 225 total points
ID: 33490315
You can use the sp_dboption 'single user' into a variable and then evaluate from there.

http://msdn.microsoft.com/en-us/library/ms187310.aspx
0
 
LVL 6

Author Comment

by:anushahanna
ID: 33502322
very excellent. Thanks.
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Slow Connectivity over ODBC 8 35
insert wont work in SQL 14 21
SQL View nearest date 5 36
Sql Query 6 66
I wrote this interesting script that really help me find jobs or procedures when working in a huge environment. I could I have written it as a Procedure but then I would have to have it on each machine or have a link to a server-related search that …
For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

773 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question