Log in
::
Register
::
Not logged in
Home
Tags
Articles
Editorials
Stairways
Forums
Scripts
Videos
Blogs
QotD
Books
Ask SSC
SQL Jobs
Training
Authors
About us
Contact us
Newsletters
Write for us
Recent Posts
Recent Posts
Popular Topics
Popular Topics
Home
Search
Members
Calendar
Who's On
Home
»
SQL Server 2008
»
SQL Server Newbies
»
User - select from master database query.
User - select from master database query.
Rate Topic
Display Mode
Topic Options
Author
Message
m.dunster
m.dunster
Posted Sunday, October 14, 2012 12:38 PM
SSC Journeyman
Group: General Forum Members
Last Login: Thursday, May 16, 2013 6:41 PM
Points: 81,
Visits: 239
Hi,
I need to access the master table to checkl the applications logged into the database for a licensing issue.
If i run the following code
select * from master.dbo.sysprocesses
when logged in as the SA or a SQL admin, it shows me what I expect. If I use it in a basic user login context, it will only show me the row relating to that login.
The guest security is enabled on the Master DB.
Is there a good way to obtain this data with a baisc user login?
Thanks,
Matthew
Post #1372525
e4d4
e4d4
Posted Sunday, October 14, 2012 2:15 PM
SSC-Enthusiastic
Group: General Forum Members
Last Login: Today @ 2:42 PM
Points: 151,
Visits: 1,036
The user must have view server state permission, to grant user that permission execute:
GRANT VIEW SERVER STATE TO yours_user;
http://msdn.microsoft.com/en-us/library/ms179881.aspx
sys.sysprocesses (Transact-SQL)
http://msdn.microsoft.com/en-us/library/ms186717.aspx
GRANT Server Permissions (Transact-SQL)
Post #1372534
m.dunster
m.dunster
Posted Monday, October 15, 2012 4:17 AM
SSC Journeyman
Group: General Forum Members
Last Login: Thursday, May 16, 2013 6:41 PM
Points: 81,
Visits: 239
e4d4 (10/14/2012)
The user must have view server state permission, to grant user that permission execute:
GRANT VIEW SERVER STATE TO yours_user;
http://msdn.microsoft.com/en-us/library/ms179881.aspx
sys.sysprocesses (Transact-SQL)
http://msdn.microsoft.com/en-us/library/ms186717.aspx
GRANT Server Permissions (Transact-SQL)
Thanks e4d4.
All working
Post #1372639
« Prev Topic
|
Next Topic »
Permissions
You
cannot
post new topics.
You
cannot
post topic replies.
You
cannot
post new polls.
You
cannot
post replies to polls.
You
cannot
edit your own topics.
You
cannot
delete your own topics.
You
cannot
edit other topics.
You
cannot
delete other topics.
You
cannot
edit your own posts.
You
cannot
edit other posts.
You
cannot
delete your own posts.
You
cannot
delete other posts.
You
cannot
post events.
You
cannot
edit your own events.
You
cannot
edit other events.
You
cannot
delete your own events.
You
cannot
delete other events.
You
cannot
send private messages.
You
cannot
send emails.
You
may
read topics.
You
cannot
rate topics.
You
cannot
vote within polls.
You
cannot
upload attachments.
You
may
download attachments.
You
cannot
post HTML code.
You
cannot
edit HTML code.
You
cannot
post IFCode.
You
cannot
post JavaScript.
You
cannot
post EmotIcons.
You
cannot
post or upload images.
Copyright © 2002-2013 Simple Talk Publishing. All Rights Reserved.
Privacy Policy.
Terms of Use.
Report Abuse.