I m trying to find out if there is a way to detect the user's assigned role ( SQL Server Role ) from my vb application in order to enable or disable some features.
There is a table in the master DB called syslogins. Within that table there are integer fields: (sysadmin, securityadmin, serveradmin, setupadmin, processadmin, diskadmin, dbcreator). If a user is a member of one or more of these roles, he/she will have a '1' in that field. Otherwise the field will be populated with a '0'.
If you use the syslogins table along with the sysusers table in your user DB(s), you should be able to retrieve any data you need to...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.