‎2014 Jan 16 11:46 PM
Hi, i hope i can explain what i need.
There are some standard reports that filter results by the authorization objects assigned to a specific user.
I've been asked to develop a report where i can filter what Dom. Sales Org, Direct Sales, Product Division can see the user depending his/her authorization objects, is there a way i can ask with a function or something, bring me all Product Divisions authorized for this user?
Maybe i can find info in SCN but i dont know how to search for this.
Thank you for any help.
‎2014 Jan 17 3:21 PM
Hi Gabriel. You can use FM SUSR_USER_AUTH_FOR_OBJ_GET. You pass the user and the auth object, and it returns a table with all fields and it's possible values by role.
Greetings
Jesus
‎2014 Jan 17 12:45 AM
Hi,
Is it related to ACE configurations in CRM. It can be done via ACE usages. Check the below links to get started.
Also check the SAP generic Auth. Object S_TABU_LIN, This is used to filter the query results based on any organizational unit defined in customizing. You functional consultant would give you a good insight about its usage.
Also check the SAP help link below:
http://help.sap.com/saphelp_erp60_sp/helpdata/en/6d/56cdd3edabc14ebd1bc84dae20dec8/content.htm
Cheers,
Arindam
‎2014 Jan 17 12:48 AM
I think you looking for this
AUTHORITY-CHECK OBJECT 'V_VBAK_VKO'
ID 'VKORG' FIELD itab-vkorg
ID 'VTWEG' FIELD itab-vtweg
ID 'SPART' FIELD itab-spart
ID 'ACTVT' FIELD '03'.
‎2014 Jan 17 2:42 AM
hi Gabriel
i don`t konw whether there are a function can get the all product divisions realated this user.
but you can using @Hai Wang mentioned statement to check. you need create a authority object(SU21) with those four field, Dom. Sales Org, Direct Sales, Product Division.
then add this object to role(PFCG), in the profile, you can add some value which is this kind of role can validated. And assign this role to user. in your program, using above statement to check.
Let`s say, you add value 1,2,3 when maintaince the role.
when using authority-check object 'XXX'
id 'field1' field '4'.
the sy-subrc will NE 0. beacuse '4' is not maintaince in your role.
some technical knowledge refer this link:http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/a92195a9-0b01-0010-909c-f330ea4a5...
regards,
Archer
‎2014 Jan 17 4:58 AM
Hi,
Please check fucntion module "AUTHORITY_CHECK".
Thanks & Regards,
Akshay Ruia
‎2014 Jan 17 3:21 PM
Hi Gabriel. You can use FM SUSR_USER_AUTH_FOR_OBJ_GET. You pass the user and the auth object, and it returns a table with all fields and it's possible values by role.
Greetings
Jesus