2007 Dec 04 7:32 AM
hi all
how to check the authorisation for a particaular user in SU53 with the object that s not present in that particular server say for example development , but that authorisation object exists in production, since we dont have access to production server how do i simulate the case in development
my problem is when a particular user runs a report he no output is displayed for the report, then they suspected like it cud be a authorisation problem,and in SU53 for a particular authorisation object it s supposed to display three field values like workcenter plant and one more field for this particular user the workcenter is displaying a value which is not present in the system
then when we debugged the pgm there a autority-check made n the program for
for that authorisation object passing run time values for those fields, since i dont have access to pdction am not able to trace the issue.
please suggest s there any other way to check how is the values getting populated for the authorisation object
hi all
how to check the authorisation for a particaular user in SU53 with the object that s not present in that particular server say for example development , but that authorisation object exists in production, since we dont have access to production server how do i simulate the case in development
my problem is when a particular user runs a report he no output is displayed for the report, then they suspected like it cud be a authorisation problem,and in SU53 for a particular authorisation object it s supposed to display three field values like workcenter plant and one more field for this particular user the workcenter is displaying a value which is not present in the system
then when we debugged the pgm there a autority-check made n the program for
for that authorisation object passing run time values for those fields, since i dont have access to pdction am not able to trace the issue.
please suggest s there any other way to check how is the values getting populated for the authorisation object
2007 Dec 04 7:34 AM
Hi,
Refer thsi code
&----
*& Form sub_check_auth_iwerk *
&----
This form checks authorization for plant. *
----
FORM sub_check_auth_iwerk .
--Constant for t code, no tcode hence value = '' (all)
CONSTANTS: lc_tcd LIKE tstc-tcode VALUE '*'.
*--Table for all the plants in selection screen. This
table will be used for authority check.
DATA: BEGIN OF li_plant OCCURS 0,
iwerk LIKE t001w-werks,
END OF li_plant.
*--Select query to pick plant from table t001w
SELECT werks "Plant
INTO TABLE li_plant
FROM t001w
WHERE werks IN s_iwerk.
LOOP AT li_plant.
AUTHORITY-CHECK OBJECT 'I_SWERK'
ID 'TCD' FIELD lc_tcd
ID 'SWERK' FIELD li_plant-iwerk.
*--Check SUBRC
IF sy-subrc NE 0.
*--No Authorization for Plant
MESSAGE e016 WITH li_plant-iwerk.
ENDIF.
ENDLOOP. "loop at li_plant
ENDFORM. "sub_check_auth_iwerk
Regards,
prashant
2007 Dec 04 10:47 PM
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |