|
-
Feb 10th, 2000, 02:45 AM
#1
Thread Starter
Addicted Member
In order to retrieve all usergroup names for a user (myusername), I am creating my own stored procedure, which calls a system procedure sp_helpuser which returns a table containing what I want
The syntax in SQL query would looks like
Use myDatabase
go
Execute sp_helpuser 'myusername'
go
I got two problems in stored procedure with it.
1) I cann't use 'USE mydatabase' in stored procedure, How to instruct sp_helpuser to check 'sysusers' table for 'mydatabase' instead of for 'master' database?
2)sp_helpuser returns a table, one of whose columns contains usergroup infomation, How to select that column out of the table and return them to my VB program(should be done in stored procedure as well, sample code please).
Your helps are greatly appreciated.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|