Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Transact-SQL (2000)
 calling one stored procedure from another

Author  Topic 

le_sloth
Starting Member

1 Post

Posted - 2003-02-18 : 06:13:37
Hi

I'm sure this question has been answered many times before, but i've had no
luck finding an answer yet!

I have one stored procedure (sp_GetUserRolesList) that returns a string
(RoleList) containing the groups that a user belongs to e.g. 'Clients,
Admins, Testers'. This procedure has one param - UserID.
I have another procedure, GetAllUserDetails, that i want to return columns:
Users.UserName, Users.UserCompany etc. (from Users table) and RoleList (from
sp_GetUserRolesList).

The data i want would be something like:

UserName | UserCompany | RoleList
Fred | ACME | Clients, Testers
Bill | Connex | Clients
Jon | ACME | Admins, Testers

How do i go about doing this? I've looked all over the place, am i supposed
to use a temp table?

Seems like such a simple problem!

thanks in advance

Rik
(using SQL Server 2000 SP3)



robvolk
Most Valuable Yak

15732 Posts

Posted - 2003-02-18 : 16:54:11
http://www.sqlteam.com/SearchResults.asp?SearchTerms=csv

Go to Top of Page
   

- Advertisement -