03-15-2010 4:23 PM
is there any function module where i can add a role to a user??
i have been trying with several with no success.
If not, can i define it when i create the user with BAPI_USER_CREATE1??
Thank you all.
Artur.
03-15-2010 5:03 PM
In transaction BAPI the FM BAPI_USER_ACTGROUP_ASSIGN is well documented.
No hack
Cheers,
Julius
03-15-2010 4:39 PM
Sorry if i sound naive on this,but what is the objective? why do you need a FM to add a role to the user?You could add it in SU01, roles tab or in PFCG users tab and then do a role comparison - isnt it?
Are you trying to use a program for the user creation? and once you have the user created, you want to use a FM for assigning a predefined set or roles? - is this what you are looking at?
03-15-2010 4:49 PM
Hey,
are you trying to find a loophole? breach security? apart from that i dont find any reason why you wanna assign roles using FM,
may be you need to justify..and if you find a FM like tht please do let me know
Thanks,
Vijay
03-15-2010 4:54 PM
Yes, it's just like Shekar.J says, I don't want to find a security breach or something like this
I want a mass creation of users.
First i create users with BAPI_USER_CREATE1.
Then i want to assign them their roles. The problem is that it is a solution manager system and for this reason i have to assign a system at the same time that i assign the role.
Thanks,
Artur.
03-15-2010 5:03 PM
In transaction BAPI the FM BAPI_USER_ACTGROUP_ASSIGN is well documented.
No hack
Cheers,
Julius
03-15-2010 5:08 PM
There is also it's sibling BAPI_USER_LOCACTGROUPS_ASSIGN if you are using CUA
03-15-2010 7:10 PM
I also forgot that you can assign a role or profile with BAPI_USER_CREATE itself as well - via a reference user for the authorization check.
Lots of options...
Cheers,
Julius
03-18-2010 10:33 PM
Hi,
you already got answer for your question. I just want to add a link to [API for identity management|http://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/668e6629-0701-0010-7ca0-994cb7dec5a3]. It is one of the best documented APIs I've ever seen from SAP.
Cheers
03-18-2010 10:37 PM
Yes, the IdM documentation is "unpeckable" and release dependently up-to-date, so be carefull of links...
Best in class at it's source and should be a benchmark for the rest of SAP!
Cheers,
Julius